Skip to content

Commit

Permalink
Form 1.7.0
Browse files Browse the repository at this point in the history
  • Loading branch information
Awilum committed Dec 20, 2020
1 parent aae42e0 commit f8f35d0
Show file tree
Hide file tree
Showing 6 changed files with 18 additions and 12 deletions.
8 changes: 7 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,11 +1,17 @@
<a name="1.7.0"></a>
# [1.7.0](https://github.com/flextype-plugins/form/compare/v1.6.0...v1.7.0) (2020-12-20)

### Features

* **core** update code base for new Flextype 0.9.13

<a name="1.6.0"></a>
# [1.6.0](https://github.com/flextype-plugins/form/compare/v1.5.1...v1.6.0) (2020-12-07)

### Features

* **core** update code base for new Flextype 0.9.12


<a name="1.5.1"></a>
# [1.5.1](https://github.com/flextype-plugins/form/compare/v1.5.0...v1.5.1) (2020-08-26)

Expand Down
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<h1 align="center">Form Plugin for <a href="https://flextype.org/">Flextype</a></h1>

<p align="center">
<a href="https://github.com/flextype-plugins/form/releases"><img alt="Version" src="https://img.shields.io/github/release/flextype-plugins/form.svg?label=version&color=black"></a> <a href="https://github.com/flextype-plugins/form"><img src="https://img.shields.io/badge/license-MIT-blue.svg?color=black" alt="License"></a> <a href="https://github.com/flextype-plugins/form"><img src="https://img.shields.io/github/downloads/flextype-plugins/form/total.svg?color=black" alt="Total downloads"></a> <a href="https://github.com/flextype/flextype"><img src="https://img.shields.io/badge/Flextype-0.9.12-green.svg?color=black" alt="Flextype"></a> <a href="https://scrutinizer-ci.com/g/flextype-plugins/form?branch=dev&color=black"><img src="https://img.shields.io/scrutinizer/g/flextype-plugins/form.svg?branch=dev" alt="Quality Score"></a> <a href=""><img src="https://img.shields.io/discord/423097982498635778.svg?logo=discord&color=black&label=Discord%20Chat" alt="Discord"></a>
<a href="https://github.com/flextype-plugins/form/releases"><img alt="Version" src="https://img.shields.io/github/release/flextype-plugins/form.svg?label=version&color=black"></a> <a href="https://github.com/flextype-plugins/form"><img src="https://img.shields.io/badge/license-MIT-blue.svg?color=black" alt="License"></a> <a href="https://github.com/flextype-plugins/form"><img src="https://img.shields.io/github/downloads/flextype-plugins/form/total.svg?color=black" alt="Total downloads"></a> <a href="https://github.com/flextype/flextype"><img src="https://img.shields.io/badge/Flextype-0.9.13-green.svg?color=black" alt="Flextype"></a> <a href="https://scrutinizer-ci.com/g/flextype-plugins/form?branch=dev&color=black"><img src="https://img.shields.io/scrutinizer/g/flextype-plugins/form.svg?branch=dev" alt="Quality Score"></a> <a href=""><img src="https://img.shields.io/discord/423097982498635778.svg?logo=discord&color=black&label=Discord%20Chat" alt="Discord"></a>
</p>

Form Plugin to render user forms for Flextype.
Expand All @@ -12,7 +12,7 @@ The following dependencies need to be installed for Form Plugin.

| Item | Version | Download |
|---|---|---|
| [flextype](https://github.com/flextype/flextype) | 0.9.12 | [download](https://github.com/flextype/flextype/releases) |
| [flextype](https://github.com/flextype/flextype) | 0.9.13 | [download](https://github.com/flextype/flextype/releases) |
| [twig](https://github.com/flextype-plugins/twig) | >=1.0.0 | [download](https://github.com/flextype-plugins/twig/releases) |
| [jquery](https://github.com/flextype-plugins/jquery) | >=1.0.0 | [download](https://github.com/flextype-plugins/jquery/releases) |

Expand Down Expand Up @@ -506,4 +506,4 @@ flextype()->post('{uri:.+}', function(Request $request, Response $response) {
## LICENSE
[The MIT License (MIT)](https://github.com/flextype-plugins/form/blob/master/LICENSE.txt)
Copyright (c) 2018-2020 [Sergey Romanenko](https://github.com/Awilum)
Copyright (c) 2021 [Sergey Romanenko](https://github.com/Awilum)
8 changes: 4 additions & 4 deletions app/Models/Fieldsets.php
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ public function fetchSingle(string $id)

if (Filesystem::has($fieldset_file)) {
if ($fieldset_body = Filesystem::read($fieldset_file)) {
if ($fieldset_decoded = flextype('yaml')->decode($fieldset_body)) {
if ($fieldset_decoded = flextype('serializers')->yaml()->decode($fieldset_body)) {
return $fieldset_decoded;
}

Expand Down Expand Up @@ -85,7 +85,7 @@ public function fetchCollection() : array
continue;
}

$fieldset_content = flextype('yaml')->decode(Filesystem::read($fieldset['path']));
$fieldset_content = flextype('serializers')->yaml()->decode(Filesystem::read($fieldset['path']));
$fieldsets[$fieldset['basename']] = $fieldset_content['title'];
}
}
Expand Down Expand Up @@ -128,7 +128,7 @@ public function update(string $id, array $data) : bool
$fieldset_file = $this->getFileLocation($id);

if (Filesystem::has($fieldset_file)) {
return Filesystem::write($fieldset_file, flextype('yaml')->encode($data));
return Filesystem::write($fieldset_file, flextype('serializers')->yaml()->encode($data));
}

return false;
Expand All @@ -149,7 +149,7 @@ public function create(string $id, array $data) : bool
$fieldset_file = $this->getFileLocation($id);

if (! Filesystem::has($fieldset_file)) {
return Filesystem::write($fieldset_file, flextype('yaml')->encode($data));
return Filesystem::write($fieldset_file, flextype('serializers')->yaml()->encode($data));
}

return false;
Expand Down
2 changes: 1 addition & 1 deletion fieldsets/fields/select_media/field.html
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{% set media_files = filesystem_list_contents(PATH_PROJECT ~ '/uploads/entries/' ~ query.id ~ '/') %}
{% set media_files = filesystem_list_contents(PATH_PROJECT ~ '/media/entries/' ~ query.id ~ '/') %}
<div class="form-group {% if properties.size %}{{ sizes[properties.size] }}{% else %}{{ sizes[12] }}{% endif %}">
<label for="{{ field_id }}" class="form-control-title">{{ tr(properties.title) }}</label>
<select class="form-control {{ properties.class }} js-select-media" name="{{ field_name }}">
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "Form",
"version": "1.6.0",
"version": "1.7.0",
"description": "Form Plugin to render user forms for Flextype.",
"homepage": "https://flextype.org",
"author": "Sergey Romanenko",
Expand Down
4 changes: 2 additions & 2 deletions plugin.yaml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
name: Form
version: 1.6.0
version: 1.7.0
description: Form Plugin to render user forms for Flextype.
icon: fas fa-check-circle
author:
Expand All @@ -14,6 +14,6 @@ keywords: form, fieldsets
license: MIT

dependencies:
flextype: 0.9.12
flextype: 0.9.13
twig: '>=1.0.0'
jquery: '>=1.0.0'

0 comments on commit f8f35d0

Please sign in to comment.