Subversion Repositories SmartDukaan

Rev

Details | Last modification | View Log | RSS feed

Rev Author Line No. Line
12449 kshitij.so 1
<html lang="en">
2
<head>
3
<title>Promotion Viewer</title>
4
<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.11.0/jquery.min.js"></script>
5
<link rel="stylesheet" type="text/css" href="/Support/css/jquery.datepick.css"> 
6
<script type="text/javascript" src="/Support/js/jquery.plugin.js"></script> 
7
<script type="text/javascript" src="/Support/js/jquery.datepick.js"></script>
8
<script type="text/javascript">
9
  $(function(){	
10
		sDate = $(startDate).datepick({dateFormat: 'yyyy-mm-dd'});
11
		eDate = $(endDate).datepick({dateFormat: 'yyyy-mm-dd'});
12
});
13
</script>
14
<script type="text/javascript">
15
  $(function(){	
16
	$(".viewPromotionDetails").on('click', function() {
17
		sDate = $('#startDate').val();
18
		eDate = $('#endDate').val();
19
		viewReport(sDate,eDate);
20
    });
21
});
22
</script>
23
<script type="text/javascript">
24
function viewReport(sDate,eDate){
25
jQuery.ajax({
26
        type : "GET",
27
        url : "/Support/amazon-list!viewPromotionDetails?startDate="+sDate+"&endDate="+eDate,
28
		success: function (data) {
29
			$('#' + 'promotion-data').html(data);
30
        },
31
		error : function() {
32
		 	alert("OOPS!!!Unable to promotion details",'ERROR');
33
		 },
34
    });  
35
}
36
</script>
37
<style>
38
	h4{
39
	color:rgb(0, 75, 145);
40
	}
41
	p {
42
    font-family: sans-serif;
43
	}
44
	.is-datepick {
45
    margin-left: 30px;
46
	}
47
	a{
48
	color: royalblue;
49
    font-family: sans-serif;
50
    font-weight: normal;
51
    text-decoration: none;
52
	}
53
	a:hover{
54
	color: #e47911;
55
	text-decoration: underline;
56
	}
57
	option{
58
	color:black;
59
	}
60
</style>
61
</head>
62
<body>
63
<a href="/Support/amazon-list/options">Go To Options</a>
64
<h4>Amazon Promotion</h4>
65
<p>Promotion Start Date: <input type="text" id="startDate" /></p>
66
<p>Promotion End&nbsp; Date: <input type="text" id="endDate" /></p>
67
<input type="button" value="View Details" class="viewPromotionDetails" />
68
<div id="promotion-data">
69
</div>
70
</body>
71
</html>