18 | @endsection
--------------------------------------------------------------------------------
/src/PublishedAssets/Views/themes/default/events/date.blade.php:
--------------------------------------------------------------------------------
1 | @extends('cms-frontend::layout.master')
2 |
3 | @section('content')
4 |
5 |
23 | @endsection
--------------------------------------------------------------------------------
/src/PublishedAssets/Views/themes/default/events/featured-template.blade.php:
--------------------------------------------------------------------------------
1 | @extends('cms-frontend::layout.master')
2 |
3 | @section('seoDescription') {{ $event->seo_description }} @endsection
4 | @section('seoKeywords') {{ $event->seo_keywords }} @endsection
5 |
6 | @section('content')
7 |
8 |
31 | @endsection
32 |
--------------------------------------------------------------------------------
/src/PublishedAssets/Views/themes/default/events/show.blade.php:
--------------------------------------------------------------------------------
1 | @extends('cms-frontend::layout.master')
2 |
3 | @section('seoDescription') {{ $event->seo_description }} @endsection
4 | @section('seoKeywords') {{ $event->seo_keywords }} @endsection
5 |
6 | @section('content')
7 |
8 |
26 | @endsection
27 |
--------------------------------------------------------------------------------
/src/PublishedAssets/Views/themes/default/faqs/all.blade.php:
--------------------------------------------------------------------------------
1 | @extends('cms-frontend::layout.master')
2 |
3 | @section('content')
4 |
5 |
35 | @endsection
--------------------------------------------------------------------------------
/src/PublishedAssets/Views/themes/default/gallery/all.blade.php:
--------------------------------------------------------------------------------
1 | @extends('cms-frontend::layout.master')
2 |
3 | @section('content')
4 |
5 |
26 | @endsection
--------------------------------------------------------------------------------
/src/PublishedAssets/Views/themes/default/gallery/show.blade.php:
--------------------------------------------------------------------------------
1 | @extends('cms-frontend::layout.master')
2 |
3 | @section('content')
4 |
5 |
26 | @endsection
--------------------------------------------------------------------------------
/src/PublishedAssets/Views/themes/default/pages/all.blade.php:
--------------------------------------------------------------------------------
1 | @extends('cms-frontend::layout.master')
2 |
3 | @section('content')
4 |
5 |
18 |
19 | @endsection
20 |
21 | @section('cms')
22 | @edit('pages')
23 | @endsection
--------------------------------------------------------------------------------
/src/PublishedAssets/Views/themes/default/pages/featured-template.blade.php:
--------------------------------------------------------------------------------
1 | @extends('cms-frontend::layout.master')
2 |
3 | @section('seoDescription') {{ $page->seo_description }} @endsection
4 | @section('seoKeywords') {{ $page->seo_keywords }} @endsection
5 |
6 | @section('content')
7 |
8 |
21 |
22 | @endsection
23 |
24 | @section('cms')
25 | @edit('pages', $page->id)
26 | @endsection
27 |
--------------------------------------------------------------------------------
/src/PublishedAssets/Views/themes/default/pages/markdown-template.blade.php:
--------------------------------------------------------------------------------
1 | @extends('cms-frontend::layout.master')
2 |
3 | @section('seoDescription') {{ $page->seo_description }} @endsection
4 | @section('seoKeywords') {{ $page->seo_keywords }} @endsection
5 |
6 | @section('content')
7 |
8 |
15 |
16 | @endsection
17 |
18 | @section('cms')
19 | @edit('pages', $page->id)
20 | @endsection
21 |
--------------------------------------------------------------------------------
/src/PublishedAssets/Views/themes/default/pages/show.blade.php:
--------------------------------------------------------------------------------
1 | @extends('cms-frontend::layout.master')
2 |
3 | @section('seoDescription') {{ $page->seo_description }} @endsection
4 | @section('seoKeywords') {{ $page->seo_keywords }} @endsection
5 |
6 | @section('content')
7 |
8 |
17 |
18 | @endsection
19 |
20 | @section('cms')
21 | @edit('pages', $page->id)
22 | @endsection
23 |
--------------------------------------------------------------------------------
/src/PublishedAssets/Views/themes/default/partials/main-menu.blade.php:
--------------------------------------------------------------------------------
1 | @foreach($links as $link)
2 | @if ($link->external)
3 |
6 | @endif
7 | @endforeach
--------------------------------------------------------------------------------
/src/PublishedAssets/Views/themes/default/public/img/pexels-photo-28938.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/GrafiteInc/CMS/0ba0d09e2db220adb9445397f627d94028cfb5d3/src/PublishedAssets/Views/themes/default/public/img/pexels-photo-28938.jpg
--------------------------------------------------------------------------------
/src/Repositories/MenuRepository.php:
--------------------------------------------------------------------------------
1 | model = $model;
18 | $this->table = config('cms.db-prefix').'menus';
19 | }
20 |
21 | /**
22 | * Stores Menu into database.
23 | *
24 | * @param array $payload
25 | *
26 | * @return Menu
27 | */
28 | public function store($payload)
29 | {
30 | $payload['name'] = htmlentities($payload['name']);
31 |
32 | return $this->model->create($payload);
33 | }
34 |
35 | /**
36 | * Updates Menu into database.
37 | *
38 | * @param Menu $menu
39 | * @param array $payload
40 | *
41 | * @return Menu
42 | */
43 | public function update($menu, $payload)
44 | {
45 | $payload['name'] = htmlentities($payload['name']);
46 |
47 | return $menu->update($payload);
48 | }
49 |
50 | /**
51 | * Set the order
52 | *
53 | * @param Menu $menu
54 | * @param array $payload
55 | *
56 | * @return Menu
57 | */
58 | public function setOrder($menu, $payload)
59 | {
60 | return $menu->update($payload);
61 | }
62 | }
63 |
--------------------------------------------------------------------------------
/src/Requests/BlogRequest.php:
--------------------------------------------------------------------------------
1 | getTemplatesAsOptionsArray('blog');
18 | }
19 | }
20 |
--------------------------------------------------------------------------------
/src/Services/CmsResponseService.php:
--------------------------------------------------------------------------------
1 | $type, 'data' => $message], $code);
20 | }
21 |
22 | /**
23 | * Generate an API error response.
24 | *
25 | * @param array $errors Validation errors
26 | * @param array $inputs Input values
27 | *
28 | * @return Response
29 | */
30 | public function apiErrorResponse($errors, $inputs)
31 | {
32 | $message = [];
33 | foreach ($inputs as $key => $value) {
34 | if (!isset($errors[$key])) {
35 | $message[$key] = [
36 | 'status' => 'valid',
37 | 'value' => $value,
38 | ];
39 | } else {
40 | $message[$key] = [
41 | 'status' => 'invalid',
42 | 'error' => $errors[$key],
43 | 'value' => $value,
44 | ];
45 | }
46 | }
47 |
48 | return Response::json(['status' => 'error', 'data' => $message]);
49 | }
50 | }
51 |
--------------------------------------------------------------------------------
/src/Services/ModuleService.php:
--------------------------------------------------------------------------------
1 | $config) {
25 | if (!is_dir($modulePath.ucfirst($module))) {
26 | $menu .= view($module.'::menu');
27 | }
28 | }
29 | }
30 |
31 | return $menu;
32 | }
33 | }
34 |
--------------------------------------------------------------------------------
/src/Services/Normalizer.php:
--------------------------------------------------------------------------------
1 | value = $value;
10 | }
11 |
12 | public function __toString()
13 | {
14 | if (is_null($this->value)){
15 | return "";
16 | }
17 |
18 | return $this->value;
19 | }
20 |
21 | public function plain()
22 | {
23 | return strip_tags($this->value);
24 | }
25 | }
26 |
--------------------------------------------------------------------------------
/src/Services/PageService.php:
--------------------------------------------------------------------------------
1 | repo = app(PageRepository::class);
14 | }
15 |
16 | /**
17 | * Get pages as options
18 | *
19 | * @return array
20 | */
21 | public function getPagesAsOptions()
22 | {
23 | $pages = [];
24 | $publishedPages = $this->repo->all();
25 |
26 | foreach ($publishedPages as $page) {
27 | $pages[$page->title] = $page->id;
28 | }
29 |
30 | return $pages;
31 | }
32 |
33 | /**
34 | * Get templates as options
35 | *
36 | * @return array
37 | */
38 | public function getTemplatesAsOptions()
39 | {
40 | return $this->getTemplatesAsOptionsArray('pages');
41 | }
42 |
43 | /**
44 | * Get a page name by ID
45 | *
46 | * @param int $id
47 | *
48 | * @return string
49 | */
50 | public function pageName($id)
51 | {
52 | $page = $this->repo->find($id);
53 |
54 | return $page->title;
55 | }
56 | }
57 |
--------------------------------------------------------------------------------
/src/Templates/AppBasic/Controller.txt:
--------------------------------------------------------------------------------
1 | service = $_lower_case_Service;
14 | }
15 |
16 | /**
17 | * Display a listing of the resource.
18 | *
19 | * @return \Illuminate\Http\Response
20 | */
21 | public function index(Request $request)
22 | {
23 | return view('cms-frontend::_lower_casePlural_.index');
24 | }
25 | }
26 |
--------------------------------------------------------------------------------
/src/Templates/AppBasic/Routes.txt:
--------------------------------------------------------------------------------
1 | /*
2 | |--------------------------------------------------------------------------
3 | | _camel_case_ App Routes
4 | |--------------------------------------------------------------------------
5 | */
6 |
7 | Route::resource('_lower_casePlural_', '_ucCamel_casePlural_Controller', ['only' => ['index']]);
8 |
--------------------------------------------------------------------------------
/src/Templates/AppBasic/Views/index.blade.txt:
--------------------------------------------------------------------------------
1 | @extends('cms-frontend::layout.master')
2 |
3 | @section('content')
4 |
5 |
10 |
11 | @endsection
12 |
13 | @section('cms')
14 | @edit('_lower_casePlural_')
15 | @endsection
--------------------------------------------------------------------------------
/src/Templates/AppCRUD/Controller.txt:
--------------------------------------------------------------------------------
1 | service = $_lower_case_Service;
14 | }
15 |
16 | /**
17 | * Display a listing of the resource.
18 | *
19 | * @return \Illuminate\Http\Response
20 | */
21 | public function index(Request $request)
22 | {
23 | $_lower_casePlural_ = $this->service->paginated();
24 | return view('cms-frontend::_lower_casePlural_.all')->with('_lower_casePlural_', $_lower_casePlural_);
25 | }
26 |
27 | /**
28 | * Display the specified resource.
29 | *
30 | * @param int $id
31 | * @return \Illuminate\Http\Response
32 | */
33 | public function show($id)
34 | {
35 | $_lower_case_ = $this->service->find($id);
36 | return view('cms-frontend::_lower_casePlural_.show')->with('_lower_case_', $_lower_case_);
37 | }
38 | }
39 |
--------------------------------------------------------------------------------
/src/Templates/AppCRUD/Routes.txt:
--------------------------------------------------------------------------------
1 | /*
2 | |--------------------------------------------------------------------------
3 | | _camel_case_ App Routes
4 | |--------------------------------------------------------------------------
5 | */
6 |
7 | Route::resource('_lower_casePlural_', '_ucCamel_casePlural_Controller', ['only' => ['show', 'index']]);
8 |
--------------------------------------------------------------------------------
/src/Templates/AppCRUD/Views/all.blade.txt:
--------------------------------------------------------------------------------
1 | @extends('cms-frontend::layout.master')
2 |
3 | @section('content')
4 |
5 |
20 |
21 | @endsection
22 |
23 | @section('cms')
24 | @edit('_lower_casePlural_')
25 | @endsection
--------------------------------------------------------------------------------
/src/Templates/AppCRUD/Views/show.blade.txt:
--------------------------------------------------------------------------------
1 | @extends('cms-frontend::layout.master')
2 |
3 | @section('content')
4 |
5 |
10 |
11 | @endsection
12 |
13 | @section('cms')
14 | @edit('_lower_casePlural_', $_lower_case_->id)
15 | @endsection
16 |
--------------------------------------------------------------------------------
/src/Templates/Basic/Controller.txt:
--------------------------------------------------------------------------------
1 | service = $_lower_case_Service;
16 | }
17 |
18 | /**
19 | * Display a listing of the resource.
20 | *
21 | * @return \Illuminate\Http\Response
22 | */
23 | public function index(Request $request)
24 | {
25 | return view('_lower_casePlural_::_lower_casePlural_.index');
26 | }
27 | }
28 |
--------------------------------------------------------------------------------
/src/Templates/Basic/Provider.txt:
--------------------------------------------------------------------------------
1 | publishes([
17 | __DIR__.'/Publishes/app' => base_path('app'),
18 | __DIR__.'/Publishes/resources' => base_path('resources'),
19 | __DIR__.'/Publishes/routes' => base_path('routes'),
20 | ]);
21 |
22 | // Load Routes
23 | $this->app->router->group(['middleware' => ['web']], function ($router) {
24 | require __DIR__.'/Routes/web.php';
25 | });
26 |
27 | // View namespace
28 | $this->app->view->addNamespace('_lower_casePlural_', __DIR__.'/Views');
29 |
30 | // Configs
31 | $this->app->config->set('cms.modules._lower_casePlural_', include(__DIR__.'/config.php'));
32 | }
33 |
34 | public function register()
35 | {
36 | // register as you please
37 | }
38 | }
--------------------------------------------------------------------------------
/src/Templates/Basic/Routes.txt:
--------------------------------------------------------------------------------
1 | /*
2 | |--------------------------------------------------------------------------
3 | | _ucCamel_casePlural_ Routes
4 | |--------------------------------------------------------------------------
5 | */
6 |
7 | Route::resource('_lower_casePlural_', '_ucCamel_casePlural_Controller', ['only' => ['index']]);
8 |
--------------------------------------------------------------------------------
/src/Templates/Basic/Service.txt:
--------------------------------------------------------------------------------
1 |
2 |
7 |
--------------------------------------------------------------------------------
/src/Templates/Basic/Views/index.blade.txt:
--------------------------------------------------------------------------------
1 | @extends('cms::layouts.dashboard')
2 |
3 | @section('content')
4 |
5 |
12 |
13 | @endsection
14 |
15 | @section('javascript')
16 |
17 | @parent
18 |
23 |
24 | @endsection
25 |
26 |
27 |
--------------------------------------------------------------------------------
/src/Templates/CRUD/CreateRequest.txt:
--------------------------------------------------------------------------------
1 | model = $_lower_case_;
32 | $this->pagination = 25;
33 | $this->table = '_table_name_';
34 | }
35 | }
36 |
--------------------------------------------------------------------------------
/src/Templates/CRUD/Facade.txt:
--------------------------------------------------------------------------------
1 | define(\App\Repositories\_camel_case_\_camel_case_::class, function (Faker\Generator $faker) {
9 | return [
10 |
11 | // prepare your table here
12 |
13 | ];
14 | });
15 |
--------------------------------------------------------------------------------
/src/Templates/CRUD/Model.txt:
--------------------------------------------------------------------------------
1 | publishes([
17 | __DIR__.'/Publishes/app' => base_path('app'),
18 | __DIR__.'/Publishes/routes' => base_path('routes'),
19 | __DIR__.'/Publishes/resources' => base_path('resources'),
20 | ]);
21 |
22 | // Load events
23 | $this->app->events->listen('eloquent.saved: Cms\Modules\_camel_casePlural_\Models\_camel_case_', 'Cms\Modules\_camel_casePlural_\Models\_camel_case_@afterSaved');
24 |
25 | // Load Routes
26 | $this->app->router->group(['middleware' => ['web']], function ($router) {
27 | require __DIR__.'/Routes/web.php';
28 | });
29 |
30 | // View namespace
31 | $this->app->view->addNamespace('_lower_casePlural_', __DIR__.'/Views');
32 |
33 | // Migrations
34 | $this->loadMigrationsFrom(__DIR__.'/Migrations');
35 |
36 | // Configs
37 | $this->app->config->set('cms.modules._lower_casePlural_', include(__DIR__.'/config.php'));
38 | }
39 | }
40 |
--------------------------------------------------------------------------------
/src/Templates/CRUD/Routes.txt:
--------------------------------------------------------------------------------
1 | /*
2 | |--------------------------------------------------------------------------
3 | | _ucCamel_casePlural_ Routes
4 | |--------------------------------------------------------------------------
5 | */
6 |
7 | Route::resource('_lower_casePlural_', '_ucCamel_casePlural_Controller', [ 'except' => ['show'], 'as' => config('cms.backend-route-prefix', 'cms') ]);
8 | Route::post('_lower_casePlural_/search', '_ucCamel_casePlural_Controller@search');
--------------------------------------------------------------------------------
/src/Templates/CRUD/UpdateRequest.txt:
--------------------------------------------------------------------------------
1 |
2 |
7 |
--------------------------------------------------------------------------------
/src/Templates/CRUD/Views/create.blade.txt:
--------------------------------------------------------------------------------
1 | @extends('cms::layouts.dashboard')
2 |
3 | @section('pageTitle') _camel_casePlural_ @stop
4 |
5 | @section('content')
6 |
7 |
8 | @include('_lower_casePlural_::_lower_casePlural_.breadcrumbs', ['location' => ['create']])
9 |
27 |
28 | @endsection
29 |
--------------------------------------------------------------------------------
/src/Templates/Composer/composer.stub:
--------------------------------------------------------------------------------
1 | {
2 | "name": "{package}",
3 | "description": "{description}",
4 | "license": "MIT",
5 | "require": {
6 | "illuminate/support": "5.*",
7 | },
8 | "require-dev": {
9 | },
10 | "autoload": {
11 | "psr-4": {
12 | "{escapedNamespace}": "src/"
13 | }
14 | },
15 | "autoload-dev": {},
16 | "scripts": {
17 | "post-install-cmd": [],
18 | "post-update-cmd": [],
19 | "post-create-project-cmd": []
20 | },
21 | "minimum-stability": "dev",
22 | "prefer-stable": true
23 | }
24 |
--------------------------------------------------------------------------------
/src/Templates/Composer/readme.stub:
--------------------------------------------------------------------------------
1 | # {package}
2 |
3 | {description}
4 |
5 | ## Requirements
6 | 4. Laravel
7 | 4. Cms
8 |
9 | ## Installation
10 |
11 | ## License
12 |
13 | {module} is open-sourced software licensed under the [MIT license](http://opensource.org/licenses/MIT)
14 |
15 | ### Bug Reporting and Feature Requests
16 |
17 | Please add as many details as possible regarding submission of issues and feature requests
18 |
19 | ### Disclaimer
20 |
21 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
22 |
--------------------------------------------------------------------------------
/src/Views/dashboard/empty.blade.php:
--------------------------------------------------------------------------------
1 | @extends('cms::layouts.dashboard')
2 |
3 | @section('pageTitle') Dashboard @stop
4 |
5 | @section('content')
6 |
7 |
8 |
9 |
10 |
The Cms dashboard is powered by Google Analytics or by its own Internal Analytics.
11 |
12 |
Internal Analytics
13 |
In order to use the internal analytics (just for this dashboard - you can still add your Google Analytics tracking to the site) simply run:
14 |
15 | php artisan migrate
16 |
17 |
18 |
Google Analytics
19 |
Grafite CMS uses the Spatie package for Google Analytics integration.
Please follow its installation instructions: https://github.com/spatie/laravel-analytics#installation
20 |
21 |
22 |
23 | @stop
24 |
--------------------------------------------------------------------------------
/src/Views/dashboard/main.blade.php:
--------------------------------------------------------------------------------
1 | @extends('cms::layouts.dashboard')
2 |
--------------------------------------------------------------------------------
/src/Views/layouts/blank.blade.php:
--------------------------------------------------------------------------------
1 | @extends('cms::layouts.dashboard')
2 |
3 | @section('pageTitle') Dashboard @stop
4 |
5 | @section('content')
6 |
7 |
8 |
9 |
Nothing to see here...
10 |
11 |
12 |
13 | @stop
14 |
--------------------------------------------------------------------------------
/src/Views/layouts/dashboard.blade.php:
--------------------------------------------------------------------------------
1 | @extends('cms::layouts.master')
2 |
3 | @section('app-content')
4 |
5 | @include('cms::layouts.notifications')
6 |
7 |
14 |
15 |
16 | @yield('content')
17 |
18 |
19 |
24 | @stop
25 |
26 | @section('javascript')
27 | {!! Minify::javascript(Cms::asset('js/dashboard.js', 'application/javascript')) !!}
28 | {!! Minify::javascript(Cms::asset('js/chart.min.js', 'application/javascript')) !!}
29 | @stop
30 |
--------------------------------------------------------------------------------
/src/Views/layouts/module-header.blade.php:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/src/Views/layouts/module-search.blade.php:
--------------------------------------------------------------------------------
1 |
2 | @if (request('term'))
3 |
4 | @endif
5 |
No {{ $module }} found.
6 |
--------------------------------------------------------------------------------
/src/Views/layouts/navigation.blade.php:
--------------------------------------------------------------------------------
1 |
17 |
--------------------------------------------------------------------------------
/src/Views/layouts/notifications.blade.php:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
--------------------------------------------------------------------------------
/src/Views/layouts/tabs.blade.php:
--------------------------------------------------------------------------------
1 | @foreach(config('cms.languages') as $short => $language)
2 |
3 | {{ ucfirst($language) }}
4 |
5 | @endforeach
6 |
--------------------------------------------------------------------------------
/src/Views/modules/blogs/breadcrumbs.blade.php:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/src/Views/modules/blogs/create.blade.php:
--------------------------------------------------------------------------------
1 | @extends('cms::layouts.dashboard')
2 |
3 | @section('pageTitle') Blog @stop
4 |
5 | @section('content')
6 |
7 |
8 | @include('cms::modules.blogs.breadcrumbs', ['location' => ['create']])
9 |
10 |
11 | {!! Form::open(['route' => cms()->route('blog.store'), 'class' => 'add', 'files' => true]) !!}
12 |
13 | {!! FormMaker::setColumns(3)->fromTable('blogs', config('cms.forms.blog.identity')) !!}
14 | {!! FormMaker::setColumns(2)->fromTable('blogs', config('cms.forms.blog.content')) !!}
15 | {!! FormMaker::setColumns(2)->fromTable('blogs', config('cms.forms.blog.seo')) !!}
16 | {!! FormMaker::setColumns(2)->fromTable('blogs', config('cms.forms.blog.publish')) !!}
17 |
18 |
19 |
Cancel
20 | {!! Form::submit('Save', ['class' => 'btn btn-primary']) !!}
21 |
22 |
23 | {!! Form::close() !!}
24 |
25 |
26 | @endsection
27 |
--------------------------------------------------------------------------------
/src/Views/modules/blogs/history.blade.php:
--------------------------------------------------------------------------------
1 | @extends('cms::layouts.dashboard')
2 |
3 | @section('pageTitle') Blog History @stop
4 |
5 | @section('content')
6 |
7 |
8 | @include('cms::modules.blogs.breadcrumbs', ['location' => [[$blog->title => cms()->url('blog/'.$blog->id.'/edit')], 'history']])
9 |
10 |
11 |
12 |
13 | @foreach($blog->history() as $history)
14 |
15 | {{ $history->created_at->format('M jS, Y') }} ({{ $history->created_at->diffForHumans() }}) |
16 |
17 | Revert
18 | |
19 |
20 | @endforeach
21 |
22 |
23 |
24 |
25 |
26 | @endsection
27 |
--------------------------------------------------------------------------------
/src/Views/modules/events/breadcrumbs.blade.php:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/src/Views/modules/events/create.blade.php:
--------------------------------------------------------------------------------
1 | @extends('cms::layouts.dashboard')
2 |
3 | @section('pageTitle') Events @stop
4 |
5 | @section('content')
6 |
7 |
8 | @include('cms::modules.events.breadcrumbs', ['location' => ['create']])
9 |
10 |
11 |
12 | {!! Form::open(['route' => cms()->route('events.store'), 'class' => 'add']) !!}
13 |
14 | {!! FormMaker::setColumns(3)->fromTable('events', config('cms.forms.event.identity')) !!}
15 | {!! FormMaker::setColumns(1)->fromTable('events', config('cms.forms.event.content')) !!}
16 | {!! FormMaker::setColumns(2)->fromTable('events', config('cms.forms.event.seo')) !!}
17 | {!! FormMaker::setColumns(2)->fromTable('events', config('cms.forms.event.publish')) !!}
18 |
19 |
20 |
Cancel
21 | {!! Form::submit('Save', ['class' => 'btn btn-primary']) !!}
22 |
23 |
24 | {!! Form::close() !!}
25 |
26 |
27 | @endsection
28 |
--------------------------------------------------------------------------------
/src/Views/modules/events/history.blade.php:
--------------------------------------------------------------------------------
1 | @extends('cms::layouts.dashboard')
2 |
3 | @section('pageTitle') Event History @stop
4 |
5 | @section('content')
6 |
7 |
8 | @include('cms::modules.events.breadcrumbs', ['location' => [[
9 | $event->title => cms()->url('events/'.$event->id.'/edit')], 'history'
10 | ]])
11 |
12 |
13 |
14 |
15 | @foreach($event->history() as $history)
16 |
17 | {{ $history->created_at->format('M jS, Y') }} ({{ $history->created_at->diffForHumans() }}) |
18 |
19 | Revert
20 | |
21 |
22 | @endforeach
23 |
24 |
25 |
26 | @endsection
27 |
--------------------------------------------------------------------------------
/src/Views/modules/faqs/breadcrumbs.blade.php:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/src/Views/modules/faqs/create.blade.php:
--------------------------------------------------------------------------------
1 | @extends('cms::layouts.dashboard')
2 |
3 | @section('pageTitle') FAQs @stop
4 |
5 | @section('content')
6 |
7 |
8 | @include('cms::modules.faqs.breadcrumbs', ['location' => ['create']])
9 |
10 |
11 |
12 | {!! Form::open(['route' => cms()->route('faqs.store'), 'class' => 'add']) !!}
13 |
14 | {!! FormMaker::fromTable('faqs', config('cms.forms.faqs')) !!}
15 |
16 |
17 |
Cancel
18 | {!! Form::submit('Save', ['class' => 'btn btn-primary']) !!}
19 |
20 |
21 | {!! Form::close() !!}
22 |
23 |
24 | @endsection
25 |
--------------------------------------------------------------------------------
/src/Views/modules/files/breadcrumbs.blade.php:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/src/Views/modules/files/create.blade.php:
--------------------------------------------------------------------------------
1 | @extends('cms::layouts.dashboard')
2 |
3 | @section('pageTitle') Files @stop
4 |
5 | @section('content')
6 |
7 |
8 | @include('cms::modules.files.breadcrumbs', ['location' => ['create']])
9 |
10 |
11 |
12 | {!! Form::open(['url' => cms()->url('files/upload'), 'files' => true, 'class' => 'dropzone', 'id' => 'fileDropzone']); !!}
13 | {!! Form::close() !!}
14 |
15 |
16 |
17 | {!! Form::open(['route' => cms()->route('files.store'), 'files' => true, 'id' => 'fileDetailsForm', 'class' => 'add']); !!}
18 |
19 | {!! FormMaker::setColumns(2)->fromTable('files', config('cms.forms.files')) !!}
20 |
21 |
22 |
Cancel
23 | {!! Form::submit('Save', ['class' => 'btn btn-primary', 'id' => 'saveFilesBtn']) !!}
24 |
25 |
26 | {!! Form::close() !!}
27 |
28 | @endsection
29 |
--------------------------------------------------------------------------------
/src/Views/modules/files/edit.blade.php:
--------------------------------------------------------------------------------
1 | @extends('cms::layouts.dashboard')
2 |
3 | @section('pageTitle') Files @stop
4 |
5 | @section('content')
6 |
7 |
8 | @include('cms::modules.files.breadcrumbs', ['location' => ['edit']])
9 |
10 |
11 |
14 |
15 |
16 | {!! Form::model($files, ['route' => [cms()->route('files.update'), $files->id], 'files' => true, 'method' => 'patch', 'class' => 'edit']) !!}
17 |
18 | {!! FormMaker::setColumns(2)->fromObject($files, config('cms.forms.file-edit')) !!}
19 |
20 |
21 |
Cancel
22 | {!! Form::submit('Save', ['class' => 'btn btn-primary']) !!}
23 |
24 |
25 | {!! Form::close() !!}
26 |
27 |
28 | @endsection
29 |
--------------------------------------------------------------------------------
/src/Views/modules/files/menu.blade.php:
--------------------------------------------------------------------------------
1 |
2 | @if (isset($createBtn))
3 |
Add New
4 | @endif
5 |
6 | {!! Form::open(['url' => cms()->url('files/search')]) !!}
7 |
8 | {!! Form::close() !!}
9 |
10 |
11 |
--------------------------------------------------------------------------------
/src/Views/modules/images/breadcrumbs.blade.php:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/src/Views/modules/images/create.blade.php:
--------------------------------------------------------------------------------
1 | @extends('cms::layouts.dashboard')
2 |
3 | @section('pageTitle') Images @stop
4 |
5 | @section('content')
6 |
7 |
8 | @include('cms::modules.images.breadcrumbs', ['location' => ['create']])
9 |
10 |
11 |
12 | {!! Form::open(['url' => cms()->url('images/upload'), 'files' => true, 'class' => 'dropzone', 'id' => 'fileDropzone']); !!}
13 | {!! Form::close() !!}
14 |
15 | {!! Form::open(['route' => cms()->route('images.store'), 'files' => true, 'id' => 'fileDetailsForm', 'class' => 'add']) !!}
16 |
17 | {!! FormMaker::fromTable('files', config('cms.forms.images')) !!}
18 |
19 |
20 |
Cancel
21 | {!! Form::submit('Save', ['class' => 'btn btn-primary', 'id' => 'saveImagesBtn']) !!}
22 |
23 |
24 | {!! Form::close() !!}
25 |
26 |
27 | @endsection
28 |
--------------------------------------------------------------------------------
/src/Views/modules/links/breadcrumbs.blade.php:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/src/Views/modules/menus/breadcrumbs.blade.php:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/src/Views/modules/menus/create.blade.php:
--------------------------------------------------------------------------------
1 | @extends('cms::layouts.dashboard')
2 |
3 | @section('pageTitle') Menus @stop
4 |
5 | @section('content')
6 |
7 |
8 | @include('cms::modules.menus.breadcrumbs', ['location' => ['create']])
9 |
10 |
11 |
12 | {!! Form::open(['route' => cms()->route('menus.store'), 'class' => 'add']) !!}
13 |
14 | {!! FormMaker::fromTable('menus', config('cms.forms.menu')) !!}
15 |
16 |
17 |
Cancel
18 | {!! Form::submit('Save', ['class' => 'btn btn-primary']) !!}
19 |
20 |
21 | {!! Form::close() !!}
22 |
23 |
24 | @endsection
25 |
26 |
--------------------------------------------------------------------------------
/src/Views/modules/menus/edit.blade.php:
--------------------------------------------------------------------------------
1 | @extends('cms::layouts.dashboard')
2 |
3 | @section('pageTitle') Menus @stop
4 |
5 | @section('content')
6 |
7 |
8 | @include('cms::modules.menus.breadcrumbs', ['location' => ['edit']])
9 |
10 |
11 |
12 | {!! Form::model($menu, ['route' => [cms()->route('menus.update'), $menu->id], 'method' => 'patch', 'class' => 'edit']) !!}
13 |
14 | {!! FormMaker::fromObject($menu, config('cms.forms.menu')) !!}
15 |
16 |
17 |
Cancel
18 | {!! Form::submit('Save', ['class' => 'btn btn-primary']) !!}
19 |
20 |
21 | {!! Form::close() !!}
22 |
23 |
24 |
25 |
26 |
27 |
28 |
29 |
Add Link
30 |
Links (Drag and drop to sort)
31 | @include('cms::modules.links.index')
32 |
33 |
34 | @endsection
35 |
36 | @section('pre_javascript')
37 |
38 | @parent
39 | var _linkOrder = @if (!is_null($menu->order)) {!! $menu->order !!} @else [] @endif;
40 | var _id = {{ $menu->id }};
41 | var _cmsUrl = _url + "/{{ config('cms.backend-route-prefix') }}";
42 |
43 | @stop
44 |
--------------------------------------------------------------------------------
/src/Views/modules/pages/breadcrumbs.blade.php:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/src/Views/modules/pages/create.blade.php:
--------------------------------------------------------------------------------
1 | @extends('cms::layouts.dashboard')
2 |
3 | @section('pageTitle') Pages @stop
4 |
5 | @section('content')
6 |
7 |
8 | @include('cms::modules.pages.breadcrumbs', ['location' => ['create']])
9 |
10 |
11 | {!! Form::open(['route' => cms()->route('pages.store'), 'class' => 'add', 'files' => true]) !!}
12 |
13 | {!! FormMaker::setColumns(2)->fromTable('pages', config('cms.forms.page.identity')) !!}
14 | {!! FormMaker::setColumns(2)->fromTable('pages', config('cms.forms.page.content')) !!}
15 | {!! FormMaker::setColumns(2)->fromTable('pages', config('cms.forms.page.seo')) !!}
16 | {!! FormMaker::setColumns(2)->fromTable('pages', config('cms.forms.page.publish')) !!}
17 |
18 |
19 |
Cancel
20 | {!! Form::submit('Save', ['class' => 'btn btn-primary']) !!}
21 |
22 |
23 | {!! Form::close() !!}
24 |
25 |
26 | @endsection
27 |
--------------------------------------------------------------------------------
/src/Views/modules/pages/history.blade.php:
--------------------------------------------------------------------------------
1 | @extends('cms::layouts.dashboard')
2 |
3 | @section('pageTitle') Page History @stop
4 |
5 | @section('content')
6 |
7 |
8 | @include('cms::modules.pages.breadcrumbs', ['location' => [[$page->title => cms()->url('pages/'.$page->id.'/edit')], 'history']])
9 |
10 |
11 |
12 |
13 | @foreach($page->history() as $history)
14 |
15 | {{ $history->created_at->format('M jS, Y') }} ({{ $history->created_at->diffForHumans() }}) |
16 |
17 | Revert
18 | |
19 |
20 | @endforeach
21 |
22 |
23 |
24 | @endsection
25 |
--------------------------------------------------------------------------------
/src/Views/modules/promotions/breadcrumbs.blade.php:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/src/Views/modules/promotions/create.blade.php:
--------------------------------------------------------------------------------
1 | @extends('cms::layouts.dashboard')
2 |
3 | @section('pageTitle') Promotions @stop
4 |
5 | @section('content')
6 |
7 |
8 | @include('cms::modules.promotions.breadcrumbs', ['location' => ['create']])
9 |
10 |
11 |
12 | {!! Form::open(['route' => cms()->route('promotions.store'), 'class' => 'add']) !!}
13 |
14 | {!! FormMaker::setColumns(3)->fromTable('promotions', config('cms.forms.promotion.identity')) !!}
15 | {!! FormMaker::setColumns(1)->fromTable('promotions', config('cms.forms.promotion.content')) !!}
16 |
17 |
18 |
Cancel
19 | {!! Form::submit('Save', ['class' => 'btn btn-primary']) !!}
20 |
21 |
22 | {!! Form::close() !!}
23 |
24 |
25 | @endsection
26 |
--------------------------------------------------------------------------------
/src/Views/modules/widgets/breadcrumbs.blade.php:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/src/Views/modules/widgets/create.blade.php:
--------------------------------------------------------------------------------
1 | @extends('cms::layouts.dashboard')
2 |
3 | @section('pageTitle') Widgets @stop
4 |
5 | @section('content')
6 |
7 |
8 | @include('cms::modules.widgets.breadcrumbs', ['location' => ['create']])
9 |
10 |
11 |
12 | {!! Form::open(['route' => cms()->route('widgets.store'), 'class' => 'add']) !!}
13 |
14 | {!! FormMaker::fromTable('widgets', config('cms.forms.widget')) !!}
15 |
16 |
17 |
Cancel
18 | {!! Form::submit('Save', ['class' => 'btn btn-primary']) !!}
19 |
20 |
21 | {!! Form::close() !!}
22 |
23 |
24 | @endsection
25 |
--------------------------------------------------------------------------------
/src/Views/notifications.blade.php:
--------------------------------------------------------------------------------
1 |
18 |
--------------------------------------------------------------------------------
/src/Views/rss.blade.php:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | @foreach($meta as $key => $metaItem)
5 | @if ($key === 'link')
6 | <{{ $key }} href="{{ $metaItem }}">{{ $key }}>
7 | @elseif ($key === 'title')
8 | <{{ $key }}>{{ $metaItem }}{{ $key }}>
9 | @else
10 | <{{ $key }}>{{ $metaItem }}{{ $key }}>
11 | @endif
12 | @endforeach
13 | @foreach($items as $item)
14 | -
15 | {{ $item->title }}
16 |
17 | {{ url($item->id) }}
18 |
19 | {{ optional($item)->author }}
20 |
21 | {!! $item->seo_description !!}
22 | {{ $item->updated_at->toAtomString() }}
23 |
24 | @endforeach
25 |
26 |
--------------------------------------------------------------------------------
/src/Views/site-map.blade.php:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | @foreach ($items as $item)
5 |
6 | {{ $item['url'] }}
7 | {{ $item['updated_at'] }}
8 | monthly
9 | 0.8
10 |
11 | @endforeach
12 |
13 |
--------------------------------------------------------------------------------
/tests/.gitkeep:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/GrafiteInc/CMS/0ba0d09e2db220adb9445397f627d94028cfb5d3/tests/.gitkeep
--------------------------------------------------------------------------------
/tests/Feature/DashboardTest.php:
--------------------------------------------------------------------------------
1 | withoutMiddleware();
13 | $this->withoutEvents();
14 | }
15 |
16 | /*
17 | |--------------------------------------------------------------------------
18 | | Landing
19 | |--------------------------------------------------------------------------
20 | */
21 |
22 | public function testIndex()
23 | {
24 | $response = $this->call('GET', '/cms/dashboard');
25 | $this->assertEquals(200, $response->getStatusCode());
26 | }
27 | }
28 |
--------------------------------------------------------------------------------
/tests/Services/BlogServiceTest.php:
--------------------------------------------------------------------------------
1 | service = app(BlogService::class);
16 | }
17 |
18 | public function testGetTemplatesAsOptions()
19 | {
20 | $result = $this->service->getTemplatesAsOptions();
21 |
22 | $this->assertTrue(is_array($result));
23 | $this->assertEquals('show', $result[0]);
24 | }
25 | }
26 |
--------------------------------------------------------------------------------
/tests/Services/CmsServiceTest.php:
--------------------------------------------------------------------------------
1 | service = app(CmsService::class);
15 | }
16 |
17 | public function testDefaultLanguage()
18 | {
19 | $result = $this->service->isDefaultLanguage();
20 |
21 | $this->assertTrue($result);
22 | }
23 |
24 | public function testNotifications()
25 | {
26 | $result = $this->service->notification('testing');
27 |
28 | $this->assertTrue(is_null($result));
29 | $this->assertEquals('testing', session()->get('notification'));
30 | }
31 |
32 | public function testBreadcrumbs()
33 | {
34 | $result = $this->service->breadcrumbs(['module']);
35 |
36 | $this->assertEquals('
Module', $result);
37 | }
38 | }
39 |
--------------------------------------------------------------------------------
/tests/Services/CryptoServiceTest.php:
--------------------------------------------------------------------------------
1 | service = app(CryptoService::class);
15 | }
16 |
17 |
18 | public function testEncrypt()
19 | {
20 | $result = $this->service->encrypt('test');
21 |
22 | $this->assertContains('--', $result);
23 | }
24 |
25 | public function testDecrypt()
26 | {
27 | $value = $this->service->encrypt('test');
28 |
29 | $result = $this->service->decrypt($value);
30 |
31 | $this->assertEquals('test', $result);
32 | }
33 | }
34 |
--------------------------------------------------------------------------------
/tests/Services/NormalizerTest.php:
--------------------------------------------------------------------------------
1 | service = new Normalizer('
sample
');
15 | }
16 |
17 | public function testToString()
18 | {
19 | $result = $this->service->__toString();
20 |
21 | $this->assertContains('sample', $result);
22 | }
23 |
24 | public function testPlain()
25 | {
26 | $result = $this->service->plain();
27 |
28 | $this->assertEquals('sample', $result);
29 | }
30 | }
31 |
--------------------------------------------------------------------------------
/tests/Services/PageServiceTest.php:
--------------------------------------------------------------------------------
1 | service = app(PageService::class);
16 |
17 | factory(Page::class)->create();
18 | }
19 |
20 | public function testGetPagesAsOptions()
21 | {
22 | $result = $this->service->getPagesAsOptions();
23 |
24 | $this->assertTrue(is_array($result));
25 | $this->assertEquals(1, count($result));
26 | }
27 |
28 | public function testGetTemplatesAsOptions()
29 | {
30 | $result = $this->service->getTemplatesAsOptions();
31 |
32 | $this->assertTrue(is_array($result));
33 | $this->assertEquals('show', $result[0]);
34 | }
35 |
36 | public function testGetPageName()
37 | {
38 | $result = $this->service->pageName(1);
39 |
40 | $this->assertEquals('dumb', $result);
41 | }
42 | }
43 |
--------------------------------------------------------------------------------
/tests/factories/BlogFactory.php:
--------------------------------------------------------------------------------
1 | define(\Grafite\Cms\Models\Blog::class, function (Faker\Generator $faker) {
10 | return [
11 | 'id' => 1,
12 | 'title' => 'dumb',
13 | 'entry' => $faker->paragraph().' '.$faker->paragraph(),
14 | 'is_published' => 1,
15 | 'url' => 'dumb',
16 | 'updated_at' => $faker->datetime(),
17 | 'created_at' => $faker->datetime(),
18 | ];
19 | });
20 |
--------------------------------------------------------------------------------
/tests/factories/EventFactory.php:
--------------------------------------------------------------------------------
1 | define(\Grafite\Cms\Models\Event::class, function (Faker\Generator $faker) {
10 | return [
11 | 'id' => 1,
12 | 'start_date' => '2016-10-31',
13 | 'end_date' => '2016-10-31',
14 | 'seo_keywords' => 'dumb, dumber',
15 | 'seo_description' => 'dumb is dumb',
16 | 'title' => 'dumb',
17 | 'details' => $faker->paragraph().' '.$faker->paragraph(),
18 | 'is_published' => 1,
19 | 'updated_at' => $faker->datetime(),
20 | 'created_at' => $faker->datetime(),
21 | ];
22 | });
23 |
--------------------------------------------------------------------------------
/tests/factories/FAQFactory.php:
--------------------------------------------------------------------------------
1 | define(\Grafite\Cms\Models\FAQ::class, function (Faker\Generator $faker) {
10 | return [
11 | 'id' => 1,
12 | 'question' => 'what\'s this?',
13 | 'answer' => 'There\'s color everywhere!',
14 | 'is_published' => 1,
15 | 'updated_at' => $faker->datetime(),
16 | 'created_at' => $faker->datetime(),
17 | ];
18 | });
19 |
--------------------------------------------------------------------------------
/tests/factories/FileFactory.php:
--------------------------------------------------------------------------------
1 | define(\Grafite\Cms\Models\File::class, function (Faker\Generator $faker) {
10 | return [
11 | 'id' => 1,
12 | 'location' => 'files/dumb',
13 | 'name' => 'dumbFile',
14 | 'tags' => 'dumb, file',
15 | 'mime' => 'txt',
16 | 'size' => 24,
17 | 'details' => 'dumb file',
18 | 'user' => 1,
19 | 'is_published' => 1,
20 | 'order' => 1,
21 | 'updated_at' => $faker->datetime(),
22 | 'created_at' => $faker->datetime(),
23 | ];
24 | });
25 |
--------------------------------------------------------------------------------
/tests/factories/ImageFactory.php:
--------------------------------------------------------------------------------
1 | define(\Grafite\Cms\Models\Image::class, function (Faker\Generator $faker) {
10 | return [
11 | 'id' => 1,
12 | 'location' => 'files/dumb',
13 | 'name' => 'dumb',
14 | 'original_name' => 'dumb',
15 | 'alt_tag' => 'dumb',
16 | 'title_tag' => 'dumb',
17 | 'is_published' => 1,
18 | 'updated_at' => $faker->datetime(),
19 | 'created_at' => $faker->datetime(),
20 | ];
21 | });
22 |
--------------------------------------------------------------------------------
/tests/factories/LinkFactory.php:
--------------------------------------------------------------------------------
1 | define(\Grafite\Cms\Models\Link::class, function (Faker\Generator $faker) {
10 | return [
11 |
12 | 'id' => 1,
13 | 'name' => 'dumb',
14 | 'external' => 1,
15 | 'page_id' => 0,
16 | 'menu_id' => 1,
17 | 'external_url' => 'http://facebook.com',
18 | 'updated_at' => $faker->datetime(),
19 | 'created_at' => $faker->datetime(),
20 |
21 | ];
22 | });
23 |
--------------------------------------------------------------------------------
/tests/factories/MenuFactory.php:
--------------------------------------------------------------------------------
1 | define(\Grafite\Cms\Models\Menu::class, function (Faker\Generator $faker) {
10 | return [
11 |
12 | 'id' => 1,
13 | 'name' => 'dumb menu',
14 | 'slug' => 'testerSLUG',
15 | 'updated_at' => $faker->datetime(),
16 | 'created_at' => $faker->datetime(),
17 |
18 | ];
19 | });
20 |
--------------------------------------------------------------------------------
/tests/factories/PageFactory.php:
--------------------------------------------------------------------------------
1 | define(\Grafite\Cms\Models\Page::class, function (Faker\Generator $faker) {
10 | return [
11 | 'id' => 1,
12 | 'title' => 'dumb',
13 | 'url' => 'dumb',
14 | 'seo_keywords' => 'dumb, dumber',
15 | 'seo_description' => 'dumb is dumb',
16 | 'entry' => $faker->paragraph().' '.$faker->paragraph(),
17 | 'is_published' => 1,
18 | 'updated_at' => $faker->datetime(),
19 | 'created_at' => $faker->datetime(),
20 | ];
21 | });
22 |
--------------------------------------------------------------------------------
/tests/factories/PromotionFactory.php:
--------------------------------------------------------------------------------
1 | define(\Grafite\Cms\Models\Promotion::class, function (Faker\Generator $faker) {
10 | return [
11 | 'id' => 1,
12 | 'published_at' => $faker->datetime()->format('Y-m-d H:i'),
13 | 'finished_at' => $faker->datetime()->format('Y-m-d H:i'),
14 | 'slug' => 'dumb',
15 | 'details' => $faker->paragraph().' '.$faker->paragraph(),
16 | 'updated_at' => $faker->datetime(),
17 | 'created_at' => $faker->datetime(),
18 | ];
19 | });
20 |
--------------------------------------------------------------------------------
/tests/factories/WidgetFactory.php:
--------------------------------------------------------------------------------
1 | define(\Grafite\Cms\Models\Widget::class, function (Faker\Generator $faker) {
10 | return [
11 | 'id' => 1,
12 | 'name' => 'test',
13 | 'slug' => 'tester',
14 | 'content' => implode(' ', $faker->paragraphs(3)),
15 | 'updated_at' => $faker->datetime(),
16 | 'created_at' => $faker->datetime(),
17 | ];
18 | });
19 |
--------------------------------------------------------------------------------
/tests/fixtures/test-file.txt:
--------------------------------------------------------------------------------
1 | what
--------------------------------------------------------------------------------
/tests/fixtures/test-pic.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/GrafiteInc/CMS/0ba0d09e2db220adb9445397f627d94028cfb5d3/tests/fixtures/test-pic.jpg
--------------------------------------------------------------------------------