Skip to content

Commit

Permalink
Fix issues version 2.1
Browse files Browse the repository at this point in the history
  • Loading branch information
biffly committed Oct 21, 2020
1 parent 50f05a3 commit ac9f595
Show file tree
Hide file tree
Showing 6 changed files with 24 additions and 7 deletions.
4 changes: 2 additions & 2 deletions MGS-forms.php
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
Plugin Name: MGS-Forms para Fusion Builder
Plugin URI: http://www.marceloscenna.com.ar
Description: Creacion de formularios y almacenado en BBDD. Permite crar de forma rapida un formulario y agregarlo utilizando Fusion Builder
Version: 2.1
Version: 2.2
Author: Marcelo Scenna
Author URI: http://www.marceloscenna.com.ar
Text Domain: mgs-forms
Expand Down Expand Up @@ -39,7 +39,7 @@
if( !defined('MGS_FORMS_BASENAME') ) define( 'MGS_FORMS_BASENAME', plugin_basename(__FILE__) );
if( !defined('MGS_FORMS_PLUGIN_DIR') ) define( 'MGS_FORMS_PLUGIN_DIR', plugin_dir_path( __FILE__ ) );
if( !defined('MGS_FORMS_PLUGIN_DIR_URL') ) define( 'MGS_FORMS_PLUGIN_DIR_URL', plugin_dir_url( __FILE__ ) );
if( !defined('MGS_FORMS_VERSION') ) define( 'MGS_FORMS_VERSION', '2.1' );
if( !defined('MGS_FORMS_VERSION') ) define( 'MGS_FORMS_VERSION', '2.2' );
if( !defined('MGS_FORMS_SLUG') ) define( 'MGS_FORMS_SLUG', 'MGS-Forms-FusionBuilder/MGS-forms.php' );
if( !defined('MGS_FORMS_PLUGIN_REMOTE_PATH') ) define( 'MGS_FORMS_PLUGIN_REMOTE_PATH', 'http://marceloscenna.com.ar/update.php' );
if( !defined('MGS_FORMS_SPECIAL_SECRET_KEY') ) define( 'MGS_FORMS_SPECIAL_SECRET_KEY', '589b4113769878.59794845' );
Expand Down
2 changes: 2 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@ https://dillinger.io/]

Creacion de formularios y almacenado en BBDD. Permite crar de forma rapida un formulario y agregarlo utilizando Fusion Builder
## Change Log
- ###### Version 2.2
- Fix issues
- ###### Version 2.1
- Add eliminar varios regitros
- ###### Version 2.0
Expand Down
3 changes: 2 additions & 1 deletion css/admin.css
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,8 @@

.mgs-select-field{width:100%;}

#mgs-registros_wrapper table.dataTable tr td input[type="checkbox"]{
#mgs-registros_wrapper table.dataTable tr td input[type="checkbox"],
#mgs-registros_wrapper table.dataTable tr th input[type="checkbox"]{
height: 1.5rem;
width: 1.5rem;
line-height: 1.5rem;
Expand Down
10 changes: 8 additions & 2 deletions inc/admin/class-main.php
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,10 @@ public function get_registros_callback(){

$sql = "SELECT * FROM ".$table_name_mgs_forms." WHERE post_id='".$form."' ORDER BY fecha DESC";

$header = array('fecha' => '-');
$header = [
'<input type="checkbox" class="mgs-forms-select-all">' => '-',
'fecha' => '-'
];
$data = array();
$exclude_data = array('unique_class', 'nonce', 'mgs-forms-ID-gen', 'mgs-forms-acc');
$exclude_data = array_merge($exclude_data, $_POST['hide']);
Expand All @@ -121,7 +124,10 @@ public function get_registros_callback(){

$resus = $wpdb->get_results($sql);
foreach( $resus as $resu ){
$t = array($resu->fecha);
$t = [
'<input type="checkbox" class="mgs-forms-ids-to-delete" value="'.$resu->id.'">',
$resu->fecha
];
$f = unserialize($resu->fields);
foreach( $f as $k=>$v ){
if( !in_array($k, $exclude_data) ){
Expand Down
6 changes: 6 additions & 0 deletions inc/admin/screen-forms.php
Original file line number Diff line number Diff line change
Expand Up @@ -111,6 +111,12 @@
});
});

jQuery('body').on('click', '.mgs-forms-select-all', function(e){
e.preventDefault();
var checkBoxes = jQuery('.mgs-forms-ids-to-delete');
checkBoxes.prop("checked", !checkBoxes.prop("checked"));
});

jQuery('body').on('click', 'button.mgs-forms-deletess', function(e){
e.preventDefault();
var to_delete = [];
Expand Down
6 changes: 4 additions & 2 deletions readme.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
Tags: forms, db
Requires at least: 4.9
Tested up to: 5.1.1
Stable tag: 2.1
Stable tag: 2.2
License: BSD 2-Clause "Simplified"
License URI: https://github.com/biffly/MGS-Forms-Fusion-Builder/blob/master/LICENSE

Expand All @@ -15,7 +15,9 @@ Creacion de formularios y almacenado en BBDD. Permite crar de forma rapida un fo
Creacion de formularios y almacenado en BBDD. Permite crar de forma rapida un formulario y agregarlo utilizando Fusion Builder

== Changelog ==
= Version 2.0 =
= Version 2.2 =
* fix issues
= Version 2.1 =
* Add eliminar varios registros
= Version 2.0 =
* Fix conflicto MGS NL Plg
Expand Down

0 comments on commit ac9f595

Please sign in to comment.