From 7e9956fdaee197af50ae011df9e5729354f688cd Mon Sep 17 00:00:00 2001 From: Edemir Santos de Paula Date: Wed, 18 Sep 2019 09:51:42 -0300 Subject: [PATCH] Fix admin input error due to acf update --- assets/js/input-5.js | 11 ++++++----- assets/js/input-5.min.js | 2 +- 2 files changed, 7 insertions(+), 6 deletions(-) diff --git a/assets/js/input-5.js b/assets/js/input-5.js index f488fc2..38192ad 100644 --- a/assets/js/input-5.js +++ b/assets/js/input-5.js @@ -1,8 +1,9 @@ -(function ($) { - // user - acf.fields.user = acf.fields.select.extend({ +(function($){ - type: 'user_network' + var Field = acf.models.SelectField.extend({ + type: 'user_network', + }); + + acf.registerFieldType( Field ); - }); })(jQuery); \ No newline at end of file diff --git a/assets/js/input-5.min.js b/assets/js/input-5.min.js index 97405e7..2a43733 100644 --- a/assets/js/input-5.min.js +++ b/assets/js/input-5.min.js @@ -1 +1 @@ -!function(e){acf.fields.user=acf.fields.select.extend({type:"user_network"})}(jQuery); \ No newline at end of file +!function(e){var field=acf.models.SelectField.extend({type:"user_network"});acf.registerFieldType(field)}(jQuery); \ No newline at end of file