summaryrefslogtreecommitdiff
path: root/views/mods/mod_kundenverwaltung/import.phtml
blob: 8bd50df13017410934c4d3a153359e76679b5179 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
<?php

	/**
	 * Template für die Importmaske in der Kundenverwaltung 
	 */

?>
<div class="wpsg_productgroups" id="wpsg-bs">
	
		<nav class="navbar navbar-default">	
			
			<div class="container-fluid">
				<div class="navbar-header">
					<a class="navbar-brand" href="#"><?php echo __('wpShopGermany', 'wpsg'); ?></a>
				</div>
				<div class="collapse navbar-collapse" id="bs-customer-navbar-collapse-1">
					<ul class="nav navbar-nav">
						<li role="presentation" class="wpsg-customer-tab-a active"><a href="#" onclick="return false;"><?php echo __("Kundenverwaltung - Kundendatenimport", "wpsg"); ?></a></li>
	          		</ul>
					<ul class="nav navbar-nav navbar-right">
						<li role="presentation" class="wpsg-customer-tab-a wpsg_showhide_filter" id="wpsg-customer-tab-0"><a href="<?php echo WPSG_URL_WP; ?>wp-admin/admin.php?page=wpsg-Customer&amp;action=index" class="add-new-h2" class="add-new-h2"><span class="glyphicon glyphicon-search"></span><?php echo __("Zurück zur Kundenverwaltung", "wpsg"); ?></a></li>
					</ul>
				</div>
			</div>	
	</nav>
	<div class="wpsg-filter wpsg-customer-tab wpsg-customer-tab-0 container-fluid from horizontal" >
		<div class="row">	
			<div class="col-lg-4">
			
				<form method="POST" action="<?php echo WPSG_URL_WP; ?>wp-admin/admin.php?page=wpsg-Customer&amp;action=import&amp;noheader=1" id="import_form" enctype="multipart/form-data">
		
					<?php wpsg_formNounce('Customer', 'import'); ?>
					
					<div class="wpsg_hinweis"><?php echo __('Laden Sie ein vorher exportiertes CSV File hoch, die Kundendaten werden dann aus dieser Datei importiert.', 'wpsg'); ?></div>
					<br />
				
					<input type="file" id="wpsg_importfile" name="wpsg_importfile" />
					
					<br /><br />
					<input type="submit" class="button-primary" value="<?php echo __('Import der Kundendaten starten', 'wpsg'); ?>" class="button-primary" name="wpsg_import" />
					
				</form>
				
				<script type="text/javascript">/* <![CDATA[ */
							  
					jQuery('#import_form').on('submit', function(evt) {
									 
						var file = jQuery('#wpsg_importfile')[0].files[0];
									
						if (file && file.size < <?php echo wpsg_get_file_upload_max_size(); ?>){
										
							return true;
										
						} else if (file) {
										
							alert("<?php echo wpsg_translate(__('Dateigröße übersteigt Upload Limit von #1#.', 'wpsg'), wpsg_formatSize(wpsg_get_file_upload_max_size())); ?>");
										
							evt.preventDefault();
							return false;
								
						} else {
						
							alert("<?php echo wpsg_translate(__('Es wurde keine Datei ausgewählt.', 'wpsg')); ?>");
										
							evt.preventDefault();
							return false;
											
						}
															
					} );
													
				/* ]]> */</script>
			</div>
		</div>
	</div>	
</div>