Subversion Repositories wpShopGermany4

Rev

Rev 6455 | Rev 7349 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 6455 Rev 7267
Line 167... Line 167...
167
				<br />
167
				<br />
168
				<input type="button" class="button" onclick="kk_sendMail(); return false;" value="<?php echo __("Absenden", "wpsg"); ?>" style="float:right;" />
168
				<input type="button" class="button" onclick="kk_sendMail(); return false;" value="<?php echo __("Absenden", "wpsg"); ?>" style="float:right;" />
169
				<div class="wpsg_clear"></div>
169
				<div class="wpsg_clear"></div>
170
				
170
				
171
			</form>
171
			</form>
-
 
172
						
-
 
173
		</div>
-
 
174
	</div>
-
 
175
 
-
 
176
<?php echo wpsg_drawForm_AdminboxEnd(); ?>
-
 
177
 
-
 
178
<?php echo wpsg_drawForm_AdminboxStart(__('SMS Versand', 'wpsg'));?>
-
 
179
 
-
 
180
	<div class="inside">
-
 
181
		<div style="padding:5px;">
-
 
182
	
-
 
183
			<form id="sms_form" method="post" action="<?php echo WPSG_URL_WP; ?>wp-admin/admin.php?page=wpsg-Order&action=ajax&mod=wpsg_mod_kundenkontakt&edit_id=<?php echo $this->view['data']['id']; ?>&do=sms_submit&noheader=1">
-
 
184
	
-
 
185
				<input type="hidden" name="_wpnonce" value="<?php echo \wp_create_nonce('wpsg_mod_kundenkontakt_sms_form_'.$this->view['data']['id']); ?>" />
-
 
186
				
-
 
187
				<p>Mit diesem Formular kann eine SMS an den Kunden versendet werden.</p>
-
 
188
									
-
 
189
				<br />
172
			
190
			
-
 
191
				<div id="numbercheck">
-
 
192
					<?php if ($this->view['valid'] === true) { ?>
-
 
193
					
-
 
194
						<div class="alert alert-success">
-
 
195
							<?php echo wpsg_translate(__('Die Telefonnummer #1# ist gültig.', 'wpsg'), $this->view['phone']); ?>
-
 
196
						</div>
-
 
197
						
-
 
198
					<?php } else { ?>
-
 
199
	
-
 
200
						<div class="alert alert-danger">
-
 
201
							<?php echo wpsg_translate(__('Die Telefonnummer #1# ist nicht gültig.', 'wpsg'), $this->view['phone']); ?>
-
 
202
						</div>
-
 
203
					
-
 
204
					<?php } ?>
-
 
205
				</div>			
-
 
206
 
-
 
207
				<br />
-
 
208
				
-
 
209
				<?php echo wpsg_drawForm_Input('phone', __('Empfänger', 'wpsg'), $this->view['phone']); ?>
-
 
210
				
-
 
211
				<br />
-
 
212
	
-
 
213
				<textarea id="text" name="text" <?php echo (($this->view['valid'] === true)?'':'disabled="disabled"'); ?> style="width:100%; height:100px;"></textarea>
-
 
214
	
-
 
215
				<input type="submit" id="sms_submit" <?php echo (($this->view['valid'] === true)?'':'disabled="disabled"'); ?> value="<?php echo __('SMS Senden', 'wpsg'); ?>" class="button" style="float:right; margin-top:15px;" />
-
 
216
	
-
 
217
				<script>
-
 
218
					
-
 
219
					jQuery('#phone').on('input', function() {
-
 
220
 
-
 
221
						jQuery('#numbercheck').html('<img src="<?php echo WPSG_URL; ?>views/gfx/ajax-loader.gif" alt="<?php echo __('Bitte warten ...', 'wpsg'); ?>" />');
-
 
222
						
-
 
223
						jQuery('#text').prop('disabled', true);
-
 
224
						jQuery('#sms_submit').prop('disabled', true);
-
 
225
						
-
 
226
						jQuery.ajax( {
-
 
227
							url: '<?php echo WPSG_URL_WP; ?>wp-admin/admin.php?page=wpsg-Order&action=ajax&mod=wpsg_mod_kundenkontakt&noheader=1&edit_id=<?php echo $_REQUEST['edit_id']; ?>&do=validateNumber',
-
 
228
							data: {
-
 
229
								'phone': jQuery('#phone').val()
-
 
230
							},
-
 
231
							success: function(data) {
-
 
232
 
-
 
233
								if (data.valid) {
-
 
234
								
-
 
235
									jQuery('#text').prop('disabled', false);
-
 
236
									jQuery('#sms_submit').prop('disabled', false);
-
 
237
									
-
 
238
								}
-
 
239
 
-
 
240
								jQuery('#numbercheck').html(data.text);
-
 
241
								
-
 
242
							}
-
 
243
						} );
-
 
244
						
-
 
245
					} );
-
 
246
					
-
 
247
				</script>
-
 
248
				
-
 
249
			</form>		
-
 
250
		
173
		</div>
251
		</div>
174
	</div>
252
	</div>
175
 
253
 
176
<?php echo wpsg_drawForm_AdminboxEnd(); ?>
254
<?php echo wpsg_drawForm_AdminboxEnd(); ?>
177
255