summaryrefslogtreecommitdiff
path: root/res
diff options
context:
space:
mode:
authoremkael <emkael@tlen.pl>2015-09-01 20:53:02 +0200
committeremkael <emkael@tlen.pl>2015-09-01 20:53:02 +0200
commit1c3fb72ac83e96e765a65186bb5e371dd1e5ebcb (patch)
tree7305de5b016878129f6f70424205fe5c54002f44 /res
parent663b0ce431635ad98908fd53689205d61f21b56f (diff)
* build tools and environment
Diffstat (limited to 'res')
-rw-r--r--res/css/bidding.css11
-rw-r--r--res/images/link.pngbin0 -> 384 bytes
-rw-r--r--res/javas/bidding.js43
3 files changed, 54 insertions, 0 deletions
diff --git a/res/css/bidding.css b/res/css/bidding.css
new file mode 100644
index 0000000..ea4ef4a
--- /dev/null
+++ b/res/css/bidding.css
@@ -0,0 +1,11 @@
+/* Tabelka licytacji */
+#bidding_popup { background-color: white; padding: 10px; border-radius: 10px; border: 1px solid black;
+ -webkit-box-shadow: 2px 2px 5px 0px rgba(0,0,0,0.75);
+ -moz-box-shadow: 2px 2px 5px 0px rgba(0,0,0,0.75);
+ box-shadow: 2px 2px 5px 0px rgba(0,0,0,0.75);
+ z-index: 1000;
+}
+#bidding_popup table { width: 100%; text-align: center; }
+#bidding_popup table th { text-align: center; }
+a.biddingLink { background: white url('../images/link.png') no-repeat; display: inline-block; width: 16px; height: 16px; position: absolute; right: 0; margin: 1px 1px 1px 3px }
+td.nol {position:relative; min-height: 16px; min-width: 55px} \ No newline at end of file
diff --git a/res/images/link.png b/res/images/link.png
new file mode 100644
index 0000000..e417d59
--- /dev/null
+++ b/res/images/link.png
Binary files differ
diff --git a/res/javas/bidding.js b/res/javas/bidding.js
new file mode 100644
index 0000000..5932e66
--- /dev/null
+++ b/res/javas/bidding.js
@@ -0,0 +1,43 @@
+var display_bidding = function(element, bidding) {
+ var popup = $('<div id="bidding_popup"></div>');
+ popup.css({
+ 'position': 'absolute',
+ 'width': '250px',
+ 'left': element.offset().left + element.width(),
+ 'top': element.offset().top
+ });
+ popup.html(bidding);
+ $('body').append(popup);
+}
+
+var load_bidding = function() {
+ $('#bidding_popup').remove();
+ var elem = $(this);
+ $.ajax(
+ {
+ url: elem.attr('data-bidding-link'),
+ complete: function(xhr, status) {
+ if (status == 'success') {
+ display_bidding(elem, xhr.responseText);
+ }
+ else {
+ display_bidding(elem, 'Brak danych');
+ }
+ }
+ }
+ );
+ return false;
+};
+
+var bind_bidding_links = function() {
+ $('a.biddingLink').each(function() {
+ $(this).unbind('click').click(load_bidding);
+ });
+ $(document).click(function() {
+ $('#bidding_popup').remove();
+ });
+};
+
+$(document).ready(function() {
+ setInterval(bind_bidding_links, 1000);
+});