diff --git a/theme/pos-interface.js b/theme/pos-interface.js
index 8488955..c844449 100644
--- a/theme/pos-interface.js
+++ b/theme/pos-interface.js
@@ -56,7 +56,7 @@

                 $button.click(function(e) {
                     if(Drupal.POS.instance) {
-                        if (pattern = $(this).data('pos-input')) {
+                        if (pattern = $(this).attr('data-pos-input')) {
                             Drupal.POS.instance.replacePattern(pattern);
                             if ($(this).data('pos-submit')) {
                                 Drupal.POS.instance.submit();
@@ -103,4 +103,4 @@
     Drupal.ajax.prototype.commands.printReceipt = function (ajax, response, status) {
         $(response.content).jqprint();
     }
-})(jQuery);
\ No newline at end of file
+})(jQuery);
