Changeset 3145292
- Timestamp:
- 09/02/2024 11:39:13 AM (19 months ago)
- Location:
- open-rdw-kenteken-voertuiginformatie/trunk
- Files:
-
- 15 edited
-
admin/AdminDashboard.php (modified) (5 diffs)
-
admin/js/open-rdw-kenteken-voertuiginformatie-admin.js (modified) (1 diff)
-
admin/logs/log.txt (modified) (1 diff)
-
app/Api.php (modified) (4 diffs)
-
app/Http/Controllers/SettingsController.php (modified) (4 diffs)
-
app/Http/Kernel.php (modified) (1 diff)
-
app/Models/History.php (modified) (2 diffs)
-
assets/admin/css/tussendoor.css (modified) (3 diffs)
-
assets/admin/js/ajax.js (modified) (1 diff)
-
assets/admin/js/dashboard.js (modified) (8 diffs)
-
config/plugin.php (modified) (3 diffs)
-
plugin-gratis-open-rdw-kenteken-voertuiginformatie.php (modified) (2 diffs)
-
readme.txt (modified) (3 diffs)
-
routes/DashboardRouter.php (modified) (1 diff)
-
views/dashboard/dashboard.home.php (modified) (5 diffs)
Legend:
- Unmodified
- Added
- Removed
-
open-rdw-kenteken-voertuiginformatie/trunk/admin/AdminDashboard.php
r3139037 r3145292 44 44 add_action('wp_ajax_rdw_save_changes', [$this, 'rdw_save_changes']); 45 45 46 add_action(' wp_enqueue_scripts', [$this, 'add_tinymce_form']);46 add_action('admin_enqueue_scripts', [$this, 'add_tinymce_form']); 47 47 add_filter('mce_buttons', [$this, 'add_tinymce_button']); 48 48 add_filter('mce_external_plugins', [$this, 'register_tinymce_button']); … … 52 52 add_action('wp_ajax_open-rdw-notice-dismiss', [$this, 'admin_notice_dismiss']); 53 53 54 //if ($license_info = $this->rdw_lisence_check(get_option('puc_license_rdw'))) {55 //if ($license_info->license != 'valid') {56 //$this->license_info = $license_info;57 //add_action('admin_init', [$this, 'notices']);58 //}59 //}54 if ($license_info = $this->rdw_lisence_check(get_option('puc_license_rdw'))) { 55 if ($license_info->license != 'valid') { 56 $this->license_info = $license_info; 57 add_action('admin_init', [$this, 'notices']); 58 } 59 } 60 60 61 61 if (isset($_POST['rdw_formatter_save']) && !empty($_POST['rdw_formatter_save'])) { … … 87 87 $now = Carbon::now(); 88 88 update_option('open-rdw-notice-dismissed', $now->addDay()->toDateString()); 89 return wp_send_json_success(); 89 90 } 90 91 … … 224 225 { 225 226 $view = new TinyMceDisplay(); 227 226 228 return $view->render(); 227 229 } … … 235 237 { 236 238 wp_enqueue_style(self::$plugin_name, plugin_dir_url(__FILE__) . 'css/open-rdw-kenteken-voertuiginformatie-admin.css', []); 237 }238 239 /**240 * Register the JavaScript for the admin area.241 *242 * @since 2.0.0243 */244 public function enqueue_scripts()245 {246 wp_enqueue_script(self::$plugin_name, plugin_dir_url(__FILE__) . 'js/open-rdw-kenteken-voertuiginformatie-admin.js', [ 'jquery' ], MainConfig::get('plugin.version'), true);247 239 } 248 240 -
open-rdw-kenteken-voertuiginformatie/trunk/admin/js/open-rdw-kenteken-voertuiginformatie-admin.js
r3138718 r3145292 40 40 }); 41 41 } 42 });43 44 /**45 * Makes an ajax call to the backend, letting it know the open-rdw-notice46 * is dismissed and should be saved as dismissed.47 */48 $(document).on('click', ".open-rdw-notice-dismiss-action", function () {49 $.ajax({50 url: ajaxurl,51 data: {52 action: "open-rdw-notice-dismiss",53 },54 });55 42 }); 56 43 -
open-rdw-kenteken-voertuiginformatie/trunk/admin/logs/log.txt
r3138769 r3145292 6 6 2024-08-21 06:25:17 - Open RDW PRO activation.. 7 7 2024-08-21 06:25:17 - Open RDW PRO activated. 8 2024-08-27 10:32:10 - Deactivating Open RDW PRO. Byebye! 9 2024-08-27 12:20:34 - Open RDW PRO activation.. 10 2024-08-27 12:20:34 - Open RDW PRO activated. -
open-rdw-kenteken-voertuiginformatie/trunk/app/Api.php
r3139133 r3145292 28 28 public function getTussendoorToken(bool $force = false): string 29 29 { 30 if (($force === true) || (get_option('tussendoor_token', '') === '')) {30 if (($force === true) || (get_option('tussendoor_token', false) === false)) { 31 31 32 32 $args = array( … … 35 35 ), 36 36 'body' => array( 37 'license' => get_option(' tussendoor_rdw_license'),37 'license' => get_option('rdw_tsd_license'), 38 38 'host' => get_site_url() 39 39 ) … … 45 45 ); 46 46 47 if (wp_remote_retrieve_response_code($request) == 201) {47 if (wp_remote_retrieve_response_code($request) === 201) { 48 48 $response = json_decode(wp_remote_retrieve_body($request), true); 49 49 update_option('tussendoor_token', $response['token']); … … 126 126 } 127 127 128 if (wp_remote_retrieve_response_code($response) == 401) {129 $this->getTussendoorToken(true);130 $this->call($url, $authorization, $method, $body);131 }132 133 128 $data = json_decode(($response['body']), true); 134 129 -
open-rdw-kenteken-voertuiginformatie/trunk/app/Http/Controllers/SettingsController.php
r3139133 r3145292 4 4 5 5 use App\Api; 6 use Exception; 6 7 use App\Updater; 7 8 use App\MainConfig; … … 78 79 $this->removeOldSettings(); 79 80 } catch (\Exception $e) { 80 $errorResponse['message'] = esc_html__(' Er is iets mis gegaan met het opslaan van de instellingen. Neem contact op met Tussendoor B.V. wanneer de fout zich voor blijft doen.');81 $errorResponse['message'] = esc_html__('TSD005: Er is iets mis gegaan met het opslaan van de instellingen. Neem contact op met Tussendoor B.V. wanneer de fout zich voor blijft doen.'); 81 82 82 83 if (WP_DEBUG) { … … 99 100 public function registerPlugin() 100 101 { 102 $request = Request::fromGlobal(); 103 104 add_filter('https_ssl_verify', '__return_false'); 105 101 106 try { 102 $request = Request::fromGlobal(); 103 104 $args = array( 105 'headers' => array( 107 $args = [ 108 'headers' => [ 106 109 'Content-Type' => 'application/x-www-form-urlencoded', 107 ),108 'body' => array(110 ], 111 'body' => [ 109 112 'id' => '24', 110 113 'action' => 'check_license', 111 114 'license' => $request->getString('license'), 112 115 'host' => get_site_url() 113 )114 );116 ] 117 ]; 115 118 116 119 $response = wp_remote_get( … … 119 122 ); 120 123 121 $licenseStatus = json_decode($response['body'])->license; 122 123 if ($licenseStatus != 'valid') { 124 throw new \Exception(); 124 if (wp_remote_retrieve_response_code($response) !== 200) { 125 throw new Exception(); 125 126 } 126 127 } catch (\Exception $e) { 127 wp_send_json_error(Updater::getNoticeMessage(), 500); 128 $errorResponse['message'] = esc_html__('TSD006: De Tussendoor API gaf een foutmelding terug. Neem contact op met Tussendoor B.V. wanneer de fout zich voor blijft doen.', 'tussendoor-rdw'); 129 130 if (WP_DEBUG) { 131 $errorResponse['debug'] = 'WP_DEBUG(TSD006) : ' . $e->getMessage(); 132 } 133 134 return wp_send_json_error($errorResponse['message'], 500); 128 135 } 129 136 130 $api = new Api; 131 $api->getTussendoorToken(true); 137 $licenseStatus = json_decode($response['body'])->license; 132 138 133 139 update_option('tsd_rdw_license_status', $licenseStatus); 134 140 update_option('rdw_tsd_license', $request->getString('license')); 135 141 136 wp_send_json_success(Updater::getNoticeMessage()); 142 if ($licenseStatus == 'valid') { 143 $api = new Api; 144 $api->getTussendoorToken(true); 145 return wp_send_json_success(Updater::getNoticeMessage()); 146 } 147 148 return wp_send_json_error(Updater::getNoticeMessage(), 500); 137 149 } 138 150 -
open-rdw-kenteken-voertuiginformatie/trunk/app/Http/Kernel.php
r3138718 r3145292 165 165 $plugin_admin = new AdminDashboard(self::getPluginName(), self::getPluginVersion()); 166 166 167 $this->loader->add_action('admin_enqueue_scripts', $plugin_admin, 'enqueue_styles'); 168 $this->loader->add_action('admin_enqueue_scripts', $plugin_admin, 'enqueue_scripts'); 167 $this->loader->add_action('wp_enqueue_scripts', $plugin_admin, 'enqueue_scripts'); 169 168 170 169 return $this->routerManager->filter('register_main_routers', [ -
open-rdw-kenteken-voertuiginformatie/trunk/app/Models/History.php
r3138718 r3145292 12 12 $api = new Api; 13 13 $authorization = $api->getTussendoorToken(); 14 $url = MainConfig::get('api.url') . '/api/plugin/rdw/v1/stats/month';14 $url = MainConfig::get('api.url') . MainConfig::get('api.endpoints.stats.month'); 15 15 16 16 try { … … 29 29 $api = new Api; 30 30 $authorization = $api->getTussendoorToken(); 31 $url = MainConfig::get('api.url') . '/api/plugin/rdw/v1/stats/today';31 $url = MainConfig::get('api.url') . MainConfig::get('api.endpoints.stats.today'); 32 32 33 33 try { -
open-rdw-kenteken-voertuiginformatie/trunk/assets/admin/css/tussendoor.css
r3138718 r3145292 2 2 3 3 #tussendoor { 4 font-family : 'Poppins', sans-serif;5 margin-left : -20px;4 font-family: 'Poppins', sans-serif; 5 margin-left: -20px; 6 6 } 7 7 8 8 #tussendoor .card-header { 9 position : relative;10 z-index : 1;11 padding-bottom : 20px !important;9 position: relative; 10 z-index: 1; 11 padding-bottom: 20px !important; 12 12 } 13 13 14 14 #tussendoor .card-footer { 15 position : relative;16 z-index : 1;17 padding-top : 20px !important;15 position: relative; 16 z-index: 1; 17 padding-top: 20px !important; 18 18 } 19 19 20 20 #tussendoor .card-header::after { 21 position : absolute;22 bottom : 0;23 top : -3rem;24 left : -3rem;25 right : -3rem;26 background-color : #f3f3f3;27 content : '';28 z-index : -1;21 position: absolute; 22 bottom: 0; 23 top: -3rem; 24 left: -3rem; 25 right: -3rem; 26 background-color: #f3f3f3; 27 content: ''; 28 z-index: -1; 29 29 } 30 30 31 31 #tussendoor .card-footer::after { 32 position : absolute;33 bottom : -3rem;34 top : 0;35 left : -3rem;36 right : -3rem;37 background-color : #f3f3f3;38 content : '';39 z-index : -1;32 position: absolute; 33 bottom: -3rem; 34 top: 0; 35 left: -3rem; 36 right: -3rem; 37 background-color: #f3f3f3; 38 content: ''; 39 z-index: -1; 40 40 } 41 41 42 42 #tussendoor .tab-pane { 43 padding-bottom : 40px;43 padding-bottom: 40px; 44 44 } 45 45 46 46 #tussendoor .u-overflow-hidden { 47 overflow : hidden;47 overflow: hidden; 48 48 } 49 49 50 50 .wp-core-ui #tussendoor select { 51 max-width : unset;51 max-width: unset; 52 52 } 53 53 54 54 #tussendoor [data-toggle="tooltip"] { 55 cursor : pointer;55 cursor: pointer; 56 56 } 57 57 58 58 #tussendoor .alert-container>div:not(.tussendoor-notice) { 59 display : none !important;59 display: none !important; 60 60 } 61 61 62 62 .tussendoor-tooltip.show { 63 opacity : 1 !important;63 opacity: 1 !important; 64 64 } 65 65 66 66 .tussendoor-tooltip .tooltip-inner { 67 font-size : 12px;68 background-color : var(--bs-primary);69 opacity : 1 !important;70 max-width : 350px;67 font-size: 12px; 68 background-color: var(--bs-primary); 69 opacity: 1 !important; 70 max-width: 350px; 71 71 } 72 72 73 73 .tussendoor-tooltip .tooltip-arrow::before { 74 border-top-color : var(--bs-primary) !important;74 border-top-color: var(--bs-primary) !important; 75 75 } 76 76 77 77 .tussendoor-tooltip.tussendoor-warning .tooltip-inner { 78 background-color : var(--bs-warning);79 color : black;78 background-color: var(--bs-warning); 79 color: black; 80 80 } 81 81 82 82 .tussendoor-tooltip.tussendoor-warning .tooltip-arrow::before { 83 border-top-color : var(--bs-warning) !important;83 border-top-color: var(--bs-warning) !important; 84 84 } 85 85 86 86 .tussendoor-tooltip.tussendoor-info .tooltip-inner { 87 background-color : var(--bs-info);87 background-color: var(--bs-info); 88 88 } 89 89 90 90 .tussendoor-tooltip.tussendoor-info .tooltip-arrow::before { 91 border-top-color : var(--bs-info) !important;91 border-top-color: var(--bs-info) !important; 92 92 } 93 93 94 94 .tussendoor-tooltip.tussendoor-danger .tooltip-inner { 95 background-color : var(--bs-danger);95 background-color: var(--bs-danger); 96 96 } 97 97 98 98 .tussendoor-tooltip.tussendoor-danger .tooltip-arrow::before { 99 border-top-color : var(--bs-danger) !important;99 border-top-color: var(--bs-danger) !important; 100 100 } 101 101 102 102 #tussendoor .input-group-prepend { 103 min-width : 335px !important;103 min-width: 335px !important; 104 104 } 105 105 … … 108 108 #tussendoor .input-group textarea, 109 109 #tussendoor .input-group select { 110 border-radius : 0 4px 4px 0;111 box-shadow : inset 0px 0px 0px 1px #eff5ff;110 border-radius: 0 4px 4px 0; 111 box-shadow: inset 0px 0px 0px 1px #eff5ff; 112 112 } 113 113 114 114 #tussendoor .input-group select, 115 115 #tussendoor .input-group input[type="number"] { 116 min-width : 320px;116 min-width: 320px; 117 117 } 118 118 119 119 #tussendoor label.input-group-text { 120 border-top-right-radius : 0;121 border-bottom-right-radius : 0;120 border-top-right-radius: 0; 121 border-bottom-right-radius: 0; 122 122 } 123 123 124 124 #tussendoor .custom-control-label::before { 125 box-shadow : none;125 box-shadow: none; 126 126 } 127 127 128 128 #tussendoor .btn-primary { 129 background-color : #2C80FF;130 border-color : #2C80FF;131 color : white;129 background-color: #2C80FF; 130 border-color: #2C80FF; 131 color: white; 132 132 } 133 133 134 134 #tussendoor .btn-xs { 135 --bs-btn-padding-y : 0.15rem;136 --bs-btn-padding-x : 0.35rem;137 --bs-btn-font-size : 0.7rem;138 --bs-btn-border-radius : 0.25rem;135 --bs-btn-padding-y: 0.15rem; 136 --bs-btn-padding-x: 0.35rem; 137 --bs-btn-font-size: 0.7rem; 138 --bs-btn-border-radius: 0.25rem; 139 139 } 140 140 141 141 #tussendoor button:disabled { 142 cursor : not-allowed;143 pointer-events : all !important;142 cursor: not-allowed; 143 pointer-events: all !important; 144 144 } 145 145 146 146 #tussendoor .fs-7 { 147 font-size : 0.8rem;147 font-size: 0.8rem; 148 148 } 149 149 150 150 #tussendoor .text-primary { 151 color : #2C80FF !important;151 color: #2C80FF !important; 152 152 } 153 153 154 154 #tussendoor a:not(.btn) { 155 color : #2C80FF;155 color: #2C80FF; 156 156 } 157 157 158 158 #tussendoor .ui-sortable li { 159 cursor : grab;159 cursor: grab; 160 160 } 161 161 162 162 #tussendoor .custom-bg-light { 163 background-color : #eff5ff;163 background-color: #eff5ff; 164 164 } 165 165 166 166 #tussendoor .custom-bg-light { 167 background-color : #f7faff;167 background-color: #f7faff; 168 168 } 169 169 170 170 #tussendoor .cursor-pointer { 171 cursor : pointer;171 cursor: pointer; 172 172 } 173 173 174 174 #tussendoor .custom-main-card { 175 min-width : 100%;176 min-height : 75%175 min-width: 100%; 176 min-height: 75% 177 177 } 178 178 179 179 #tussendoor .custom-text-height-1 { 180 display : -webkit-box;181 -webkit-line-clamp : 1;182 -webkit-box-orient : vertical;183 overflow : hidden;180 display: -webkit-box; 181 -webkit-line-clamp: 1; 182 -webkit-box-orient: vertical; 183 overflow: hidden; 184 184 } 185 185 186 186 #tussendoor .custom-text-height-2 { 187 display : -webkit-box;188 -webkit-line-clamp : 2;189 -webkit-box-orient : vertical;190 overflow : hidden;187 display: -webkit-box; 188 -webkit-line-clamp: 2; 189 -webkit-box-orient: vertical; 190 overflow: hidden; 191 191 } 192 192 193 193 #tussendoor .custom-min-view-height-100 { 194 min-height : 100vh;194 min-height: 100vh; 195 195 } 196 196 197 197 #tussendoor .custom-min-view-height-90 { 198 min-height : 90vh;198 min-height: 90vh; 199 199 } 200 200 201 201 #tussendoor .custom--center-align { 202 position : absolute;203 left : 50%;204 top : 50%;205 transform : translate(-50%, -50%);202 position: absolute; 203 left: 50%; 204 top: 50%; 205 transform: translate(-50%, -50%); 206 206 } 207 207 208 208 #tussendoor .tab-title h3 { 209 font-size : 20px;209 font-size: 20px; 210 210 } 211 211 212 212 #tussendoor .tab-title h4 { 213 font-size : 18px;213 font-size: 18px; 214 214 } 215 215 216 216 #tussendoor .wizard .tab-content { 217 padding-bottom : 100px !important;217 padding-bottom: 100px !important; 218 218 } 219 219 220 220 #tussendoor .card-footer-content .custom-button-width { 221 width : 100px;221 width: 100px; 222 222 } 223 223 224 224 #tussendoor .card-footer-content .custom-button-width.feedback { 225 width : 105px;225 width: 105px; 226 226 } 227 227 228 228 #tussendoor .card-header .card-title { 229 font-size : 30px;229 font-size: 30px; 230 230 } 231 231 232 232 #tussendoor .card-header .notice-dismiss { 233 position : relative;234 padding : 0px;233 position: relative; 234 padding: 0px; 235 235 } 236 236 237 237 #tussendoor .card-header .alert-container { 238 display : flex;239 flex-direction : column;238 display: flex; 239 flex-direction: column; 240 240 } 241 241 242 242 #tussendoor .card-header .notice, 243 243 #tussendoor .card-header .alert { 244 width : fit-content;244 width: fit-content; 245 245 } 246 246 247 247 #tussendoor .card-header .notice { 248 margin-left : 0px;249 margin-bottom : 0px;250 --bs-alert-bg : transparent;251 --bs-alert-padding-x : 12px;252 --bs-alert-padding-y : 12px;253 --bs-alert-margin-bottom : 1rem;254 --bs-alert-color : inherit;255 --bs-alert-border-color : transparent;256 --bs-alert-border : 1px solid var(--bs-alert-border-color);257 --bs-alert-border-radius : 0.375rem;258 position : relative;259 padding : var(--bs-alert-padding-y) var(--bs-alert-padding-x);260 margin-bottom : var(--bs-alert-margin-bottom);261 color : var(--bs-alert-color);262 background-color : var(--bs-alert-bg);263 border : var(--bs-alert-border);264 border-radius : var(--bs-alert-border-radius);265 font-size : 14px;266 display : inline-block;248 margin-left: 0px; 249 margin-bottom: 0px; 250 --bs-alert-bg: transparent; 251 --bs-alert-padding-x: 12px; 252 --bs-alert-padding-y: 12px; 253 --bs-alert-margin-bottom: 1rem; 254 --bs-alert-color: inherit; 255 --bs-alert-border-color: transparent; 256 --bs-alert-border: 1px solid var(--bs-alert-border-color); 257 --bs-alert-border-radius: 0.375rem; 258 position: relative; 259 padding: var(--bs-alert-padding-y) var(--bs-alert-padding-x); 260 margin-bottom: var(--bs-alert-margin-bottom); 261 color: var(--bs-alert-color); 262 background-color: var(--bs-alert-bg); 263 border: var(--bs-alert-border); 264 border-radius: var(--bs-alert-border-radius); 265 font-size: 14px; 266 display: inline-block; 267 267 } 268 268 269 269 #tussendoor .alert.alert-sm { 270 padding : .5rem;271 font-size : 0.7rem;270 padding: .5rem; 271 font-size: 0.7rem; 272 272 } 273 273 274 274 #tussendoor .card-header .notice-error, 275 275 #tussendoor .alert-error { 276 background-color : #f8d7da;277 border-color : #f5c6cb;278 color : #721c24;276 background-color: #f8d7da; 277 border-color: #f5c6cb; 278 color: #721c24; 279 279 } 280 280 281 281 #tussendoor .card-header .notice-warning, 282 282 #tussendoor .alert-warning { 283 color : #856404;284 background-color : #fff3cd;285 border-color : #ffeeba;283 color: #856404; 284 background-color: #fff3cd; 285 border-color: #ffeeba; 286 286 } 287 287 288 288 #tussendoor .card-header .notice-succes, 289 289 #tussendoor .alert-succes { 290 color : #155724;291 background-color : #d4edda;292 border-color : #c3e6cb;290 color: #155724; 291 background-color: #d4edda; 292 border-color: #c3e6cb; 293 293 } 294 294 295 295 #tussendoor .card-header .notice-info, 296 296 #tussendoor .alert-info { 297 color : #004085;298 background-color : #cce5ff;299 border-color : #b8daff;297 color: #004085; 298 background-color: #cce5ff; 299 border-color: #b8daff; 300 300 } 301 301 302 302 #tussendoor .card-inner-body .nav-item .nav-link { 303 font-weight : 100 !important;303 font-weight: 100 !important; 304 304 } 305 305 306 306 #tussendoor .card-inner-body .nav-item .nav-link.active { 307 font-weight : 500 !important;307 font-weight: 500 !important; 308 308 } 309 309 310 310 #tussendoor .card-inner-body .nav-item .nav-link:focus { 311 outline : 0 !important;312 box-shadow : none !important;311 outline: 0 !important; 312 box-shadow: none !important; 313 313 } 314 314 315 315 #tussendoor .card-inner-body .nav-item .nav-link:hover, 316 316 #tussendoor .card-inner-body .nav-item .nav-link:active { 317 color : #007bff317 color: #007bff 318 318 } 319 319 320 320 #tussendoor #item_wrapper .item .part { 321 width : 10%;321 width: 10%; 322 322 } 323 323 324 324 #tussendoor #item_wrapper .item .wide { 325 width : 25%;325 width: 25%; 326 326 } 327 327 328 328 #tussendoor .dashboard-navigation { 329 width : 250px;329 width: 250px; 330 330 } 331 331 332 332 #tussendoor .dashboard-panels { 333 width : calc(80% - 250px - -2rem);333 width: calc(80% - 250px - -2rem); 334 334 } 335 335 336 336 #tussendoor .alert .custom--close-alert { 337 cursor : pointer;338 top : 2px;339 right : 2px337 cursor: pointer; 338 top: 2px; 339 right: 2px 340 340 } 341 341 342 342 #tussendoor .u-hidden { 343 display : none;343 display: none; 344 344 } 345 345 346 346 #tussendoor .badge-xs-custom { 347 font-size : 9px;347 font-size: 9px; 348 348 top: 5px; 349 349 } … … 355 355 @media (min-width: 992px) { 356 356 #tussendoor .card .nav.flex-lg-column>li { 357 border-bottom : 1px solid rgba(0, 0, 0, .125);358 margin : 0;357 border-bottom: 1px solid rgba(0, 0, 0, .125); 358 margin: 0; 359 359 } 360 360 } 361 362 #app-container .form input.error { 363 border: 1px solid red; 364 } 365 366 .modal.show .modal-dialog.tussendoor { 367 transform: none; 368 top: 15px; 369 } 370 371 .modal-header.tussendoor { 372 border-bottom: none; 373 } 374 375 .modal-footer.tussendoor { 376 border-top: none; 377 justify-content: flex-start; 378 margin-left: 35px; 379 margin-bottom: 35px; 380 } 381 382 .modal-body.tussendoor { 383 padding: 0px 50px 0px 50px; 384 } 385 386 #free-variant-notice { 387 background-color: red; 388 color: white; 389 border-radius: 20px; 390 } 391 392 .modal-dialog-extra { 393 position: relative; 394 max-width: 500px; 395 margin-left: auto; 396 margin-right: auto; 397 pointer-events: none; 398 top: -50px; 399 } 400 401 .modal-dialog-extra #free-variant-notice { 402 background-color: white; 403 color: black; 404 border-radius: 0px 0px 20px 20px; 405 z-index: -1; 406 padding-top: 35px; 407 } 408 409 .accordion.tussendoor { 410 margin-top: 25px; 411 margin-bottom: 25px; 412 } 413 414 .accordion-button:not(.collapsed) { 415 color: black; 416 background-color: gainsboro; 417 } -
open-rdw-kenteken-voertuiginformatie/trunk/assets/admin/js/ajax.js
r3138718 r3145292 27 27 $('button[type="submit"]', form).removeClass('btn-success btn-danger').addClass('btn-primary'); 28 28 }, 2000); 29 }); 30 }); 31 32 33 /** 34 * Makes an ajax call to the backend, letting it know the open-rdw-notice 35 * is dismissed and should be saved as dismissed. 36 */ 37 $(document).on('click', ".open-rdw-notice-dismiss-action", function () { 38 $.ajax({ 39 url: ajaxurl, 40 cache: false, 41 type: "GET", 42 data: { 43 action: "open-rdw-notice-dismiss", 44 }, 29 45 }); 30 46 }); -
open-rdw-kenteken-voertuiginformatie/trunk/assets/admin/js/dashboard.js
r3138718 r3145292 1 jQuery(document).ready(function ($) {2 const $document = $(document);1 jQuery(document).ready(function ($) { 2 const $document = $(document); 3 3 4 const tooltipTriggerList = document.querySelectorAll('[data-bs-toggle="tooltip"]');4 const tooltipTriggerList = document.querySelectorAll('[data-bs-toggle="tooltip"]'); 5 5 [...tooltipTriggerList].map(tooltipTriggerEl => new bootstrap.Tooltip(tooltipTriggerEl)); 6 6 … … 12 12 13 13 function handleTabChangeInHistory() { 14 14 15 15 let url = window.location.href; 16 16 let baseUrl = url.split('?')[0] 17 17 18 18 let target = $(this).attr('id'); 19 19 let searchParams = new URLSearchParams(window.location.search) 20 20 21 21 searchParams.set('tab', target); 22 22 23 23 let newUrl = baseUrl + '?' + searchParams.toString(); 24 24 history.pushState({}, null, newUrl); 25 25 } 26 26 27 function toggleCheckboxValue(e) 28 { 27 function toggleCheckboxValue(e) { 29 28 if ($(this).is(':checked')) { 30 29 $(this).attr('value', '1'); … … 34 33 } 35 34 36 function toggleExtraContentCeckbox(event) 37 { 38 let target = $(event.target).data('target'); 39 let $content = $('.js--extra-content-target[data-for=' + target + ']'); 35 function toggleExtraContentCeckbox(event) { 36 let target = $(event.target).data('target'); 37 let $content = $('.js--extra-content-target[data-for=' + target + ']'); 40 38 41 $content.each(function () {39 $content.each(function () { 42 40 43 var checkboxIsChecked = $(event.target).is(':checked');44 var enableReversed = (!checkboxIsChecked && $(this).hasClass('reversed'));45 var enableDefault = (checkboxIsChecked && !$(this).hasClass('reversed'));41 var checkboxIsChecked = $(event.target).is(':checked'); 42 var enableReversed = (!checkboxIsChecked && $(this).hasClass('reversed')); 43 var enableDefault = (checkboxIsChecked && !$(this).hasClass('reversed')); 46 44 47 if (enableReversed || enableDefault) {45 if (enableReversed || enableDefault) { 48 46 if ($(this).hasClass('extra-content-is-flexed')) { 49 47 $(this).css('display', 'flex'); … … 56 54 disableFieldsInContent($(this)); 57 55 } 58 });59 56 }); 57 60 58 } 61 59 62 60 function toggleExtraContentSelect() { 63 let toggleValue= $(this).data('toggle-value');64 let value= $(this).val();65 let target= $(this).data('target');66 let $content= $('.js--extra-content-target[data-for=' + target + ']');61 let toggleValue = $(this).data('toggle-value'); 62 let value = $(this).val(); 63 let target = $(this).data('target'); 64 let $content = $('.js--extra-content-target[data-for=' + target + ']'); 67 65 68 66 // Create array if multiple values are possible … … 71 69 } 72 70 73 $content.each(function() {71 $content.each(function () { 74 72 // if toggleValue is an array and value is not in the array then hide and disable the content 75 73 // if toggleValue is a string and not equal to value then hide and disable the content … … 86 84 } 87 85 } 88 });86 }); 89 87 } 90 88 91 function showAndEnableContent($content) 92 { 89 function showAndEnableContent($content) { 93 90 $content.slideDown(); 94 91 enableFieldsInContent($content); 95 92 } 96 93 97 function hideAndDisableContent($content) 98 { 94 function hideAndDisableContent($content) { 99 95 $content.slideUp(); 100 96 disableFieldsInContent($content); 101 97 } 102 98 103 function enableFieldsInContent($content) 104 { 99 function enableFieldsInContent($content) { 105 100 $('input', $content).prop('disabled', false).removeClass('disabled'); 106 101 $('select', $content).prop('disabled', false).removeClass('disabled'); … … 108 103 } 109 104 110 function disableFieldsInContent($content) 111 { 105 function disableFieldsInContent($content) { 112 106 $('input', $content).prop('disabled', true).addClass('disabled'); 113 107 $('select', $content).prop('disabled', true).addClass('disabled'); … … 117 111 /** 118 112 * When adding custom alerts with a manual removal we can remove the alert via this method 119 * 113 * 120 114 * @see alert.js 121 * 122 * @param {object} e 115 * 116 * @param {object} e 123 117 */ 124 function removeAlert(e) 125 { 118 function removeAlert(e) { 126 119 e.target.parentNode.remove(); 127 120 } -
open-rdw-kenteken-voertuiginformatie/trunk/config/plugin.php
r3139733 r3145292 27 27 'log_source' => 'tussendoor-rdw', 28 28 'log_context' => 'tsdRdwContext', 29 'version' => '5.0. 4.8',29 'version' => '5.0.5', 30 30 'php_minimum' => '8.0', 31 31 'php_minimum_id' => 80000, … … 54 54 'textversion' => '2.0.0', 55 55 'version' => 'v2', 56 'url' => 'https://tussendoor. nl',56 'url' => 'https://tussendoor.test', 57 57 'timezone' => 'Europe/Amsterdam', 58 58 'endpoints' => [ … … 65 65 'stats' => [ 66 66 'month' => '/api/plugin/rdw/v2/stats/month', 67 'today' => '/api/plugin/rdw/v2/stats/today'67 'today' => '/api/plugin/rdw/v2/stats/today' 68 68 ], 69 69 'licenseplate' => [ -
open-rdw-kenteken-voertuiginformatie/trunk/plugin-gratis-open-rdw-kenteken-voertuiginformatie.php
r3139733 r3145292 12 12 * Author URI: https://www.tussendoor.nl 13 13 * Text Domain: tussendoor-rdw 14 * Version: 5.0. 4.814 * Version: 5.0.5 15 15 * Tested up to: 6.6.1 16 16 * Requires at least: 6.2 … … 28 28 define('ORK_PLUGIN_PATH', plugins_url('tussendoor-rdw')); 29 29 define('ORK_PLUGIN', __DIR__); 30 define('ORK_VERSION', '5.0. 4.8');30 define('ORK_VERSION', '5.0.5'); 31 31 32 32 /** -
open-rdw-kenteken-voertuiginformatie/trunk/readme.txt
r3139733 r3145292 2 2 Contributors: Tussendoor 3 3 Tags: tussendoor, rdw, kenteken, voertuig, kentekeninformatie 4 Stable tag: 5.0. 4.84 Stable tag: 5.0.5 5 5 Tested up to: 6.6.1 6 6 Requires at least: 6.2 … … 9 9 License URI: http://www.gnu.org/licenses/gpl-2.0.txt 10 10 11 Haal kenteken / voertuig informatie op van OpenRDW met de tussendoor-rdw.11 Haal kenteken / voertuig informatie op van OpenRDW met de Open RDW Kenteken plugin. 12 12 13 13 ## Description 14 Met de Open RDW Kenteken plugin van [Tussendoor](http ://www.tussendoor.nl), haal je op een eenvoudige wijze kenteken en voertuig informatie op via de gratis dienst van de RDW ([Open RDW](http://www.rdw.nl/Zakelijk/Paginas/Open-data.aspx))14 Met de Open RDW Kenteken plugin van [Tussendoor](https://www.tussendoor.nl), haal je op een eenvoudige wijze kenteken en voertuig informatie op via de gratis dienst van de RDW ([Open RDW](https://www.rdw.nl/)) 15 15 16 16 … … 41 41 2. Activeer de plugin onder de plugin pagina. 42 42 3. Voer de licentie in die je van Tussendoor hebt ontvangen. 43 4. Ga naar Widgets, pagina / berichten beheer of Contact Form 7 om je eerste kentekencontrole in te bouwen en direct gratis te gebruiken. 44 45 ### Screenshots 46 47 1. Standaard instellingen scherm Open RDW - Informatie over integraties 48 2. Voorbeeldscherm Contact Form 7 integratie bij Open RDW plugin 49 3. Voorbeelscherm Widgets voor het integreren van kentekeninformatie via een widget / sidebar 50 4. Voorbeeldscherm (stap 1) voor de shortcode invoer binnen de WYSIWYG editor 51 5. Voorbeeldscherm (stap 2) voor de shortcode invoer binnen de WYSIWYG editor 43 4. Ga naar Widgets, pagina / berichten beheer of formulier builder om je eerste kentekencontrole in te bouwen en direct gratis te gebruiken. 52 44 53 45 ### Changelog 46 47 ##### 5.0.5 48 * Fixed: Check whether dateTime is compatible with Carbon Parse. 49 * Removed: Older styles where enqueued. 50 * Update: Stats now use v2 enpoints. 51 * Update: Stability improvements on activating plugin with license. 52 * Update: Stability improvements in JavaScript. 53 * Update: Readme.md. 54 54 55 55 ##### 5.0.4.8 -
open-rdw-kenteken-voertuiginformatie/trunk/routes/DashboardRouter.php
r3138718 r3145292 66 66 { 67 67 /** 68 * Filter: tussendoor_ bol_enqueue_assets68 * Filter: tussendoor_rdw_enqueue_assets 69 69 * Can be used by third-parties or add-ons to return early and prevent the plugin from enqueuing assets 70 70 * 71 71 * @return bool 72 72 */ 73 $returnEarly = apply_filters('tussendoor_ bol_enqueue_assets', (strpos($hook, MainConfig::get('plugin.tag')) === false), $hook);73 $returnEarly = apply_filters('tussendoor_rdw_enqueue_assets', (strpos($hook, MainConfig::get('plugin.tag')) === false), $hook); 74 74 if ($returnEarly) return; 75 75 -
open-rdw-kenteken-voertuiginformatie/trunk/views/dashboard/dashboard.home.php
r3139733 r3145292 13 13 $currentTime = Carbon::now()->toDateString(); 14 14 15 if ($dismissTime === false || $dismissTime === '' || (Carbon::parse($currentTime)->greaterThan($dismissTime))) : ?> 15 if ( 16 $dismissTime === false || 17 $dismissTime === '' || 18 $dismissTime == '1' || 19 (Carbon::parse($currentTime)->greaterThan($dismissTime)) 20 ) : ?> 16 21 <script> 17 22 document.addEventListener('DOMContentLoaded', function() { … … 56 61 <!-- Modal --> 57 62 <div class="modal fade" id="staticBackdrop" data-bs-backdrop="static" data-bs-keyboard="false" tabindex="-1" aria-labelledby="staticBackdropLabel" aria-hidden="true"> 58 <div class="modal-dialog ">63 <div class="modal-dialog tussendoor"> 59 64 <div class="modal-content" id="free-variant-notice"> 60 <div class="modal-header ">65 <div class="modal-header tussendoor"> 61 66 <button type="button" class="btn-close open-rdw-notice-dismiss-action" data-bs-dismiss="modal" aria-label="Close"></button> 62 67 </div> 63 <div class="modal-body ">68 <div class="modal-body tussendoor"> 64 69 <i class="fa-regular fa-calendar" style="font-size:48px; color:orange;"></i> 65 70 <h1 class="modal-title fs-4" id="staticBackdropLabel">Vanaf 1 oktober verandert het betaalmodel van deze plugin.</h1> 66 71 </div> 67 <div class="modal-footer ">72 <div class="modal-footer tussendoor"> 68 73 <p>Waarom? <a href="https://tussendoor.nl/ons-betaalmodel-verandert" target="_blank">Hier vind je meer informatie</a></p> 69 74 </div> … … 72 77 <div class="modal-dialog-extra"> 73 78 <div class="modal-content" id="free-variant-notice"> 74 <div class="modal-header ">79 <div class="modal-header tussendoor"> 75 80 </div> 76 <div class="modal-body ">81 <div class="modal-body tussendoor"> 77 82 <h1 class="modal-title fs-5" id="staticBackdropLabel">Meld je aan om de gratis periode tot 1 november te verlengen.</h1> 78 83 <br> … … 84 89 <a href="https://tussendoor.nl/plugins/openrdw-kenteken-wordpress-plugin" target="_blank" class="btn btn-secondary rounded-pill fw-light custom-button-width me-3" type="button"> Bekijk de pakketten <i class="fa-solid fa-arrow-right"></i></a> 85 90 </div> 86 <div class="accordion " id="accordionExample">91 <div class="accordion tussendoor" id="accordionExample"> 87 92 <div class="accordion-item"> 88 93 <h2 class="accordion-header" id="headingOne"> … … 124 129 </div> 125 130 </div> 126 <div class="modal-footer "></div>131 <div class="modal-footer tussendoor"></div> 127 132 </div> 128 133 </div>
Note: See TracChangeset
for help on using the changeset viewer.