├── debian ├── conffiles ├── compat ├── salor-hospitality.links ├── salor-hospitality.manpages ├── salor-hospitality.docs ├── source │ └── format ├── docs ├── menu ├── salor-hospitality.dirs ├── README ├── README.source ├── salor-hospitality.cron.d ├── bin │ ├── salor-hospitality.desktop │ └── salor-hospitality ├── rules ├── salor-hospitality.doc-base.EX ├── salor-hospitality.templates ├── control └── salor-hospitality.install ├── salor-hospitality ├── log │ └── .gitkeep ├── tmp │ └── .gitkeep ├── .rspec ├── app │ ├── mailers │ │ ├── .gitkeep │ │ └── user_mailer.rb │ ├── models │ │ ├── .gitkeep │ │ ├── email.rb │ │ ├── item_type.rb │ │ ├── user_messages.rb │ │ ├── statistic_category.rb │ │ ├── user_login.rb │ │ ├── camera.rb │ │ ├── cash_register.rb │ │ ├── coupon.rb │ │ ├── cash_drawer.rb │ │ ├── discount.rb │ │ ├── reservation.rb │ │ └── room_type.rb │ ├── views │ │ ├── customers │ │ │ ├── show.html.haml │ │ │ ├── index.csv.erb │ │ │ └── index.html.haml │ │ ├── orders │ │ │ ├── _customers.html.haml │ │ │ ├── _functions_header_digital_menucard.html.haml │ │ │ ├── _note.haml │ │ │ ├── _functions_header_last_invoices.html.haml │ │ │ ├── _functions_header_invoice_form.html.haml │ │ │ ├── render_invoice_form.js.erb │ │ │ ├── _areas.html.haml │ │ │ ├── last_invoices.js.erb │ │ │ ├── render_order_form.js.erb │ │ │ ├── _functions_header_index.haml │ │ │ └── _order_form.html.haml │ │ ├── exception_notifier │ │ │ ├── _backtrace.html.erb │ │ │ ├── _backtrace.text.erb │ │ │ ├── _data.html.erb │ │ │ ├── _data.text.erb │ │ │ ├── _title.html.erb │ │ │ ├── _title.text.erb │ │ │ ├── _session.html.erb │ │ │ ├── _session.text.erb │ │ │ ├── _request.html.erb │ │ │ ├── _request.text.erb │ │ │ ├── _salor.text.erb │ │ │ ├── _environment.html.erb │ │ │ ├── _environment.text.erb │ │ │ ├── background_exception_notification.text.erb │ │ │ ├── background_exception_notification.html.erb │ │ │ ├── exception_notification.text.erb │ │ │ └── exception_notification.html.erb │ │ ├── vendors │ │ │ ├── edit.html.haml │ │ │ ├── new.html.haml │ │ │ └── index.html.haml │ │ ├── sessions │ │ │ ├── _screenlock.html.haml │ │ │ ├── new_customer.html.haml │ │ │ └── new.html.haml │ │ ├── partials │ │ │ ├── no_presentation_found.js.erb │ │ │ ├── create.js.erb │ │ │ ├── update.js.erb │ │ │ └── _simple_partial.html.haml │ │ ├── pages │ │ │ ├── edit.html.haml │ │ │ ├── new.html.haml │ │ │ ├── find.js.erb │ │ │ ├── refresh.js.erb │ │ │ ├── _page.html.haml │ │ │ ├── _pages.html.haml │ │ │ ├── index.html.haml │ │ │ └── show.html.haml │ │ ├── statistics │ │ │ ├── _print_footer.txt.erb │ │ │ ├── _print_statistics_sold_quantities.txt.erb │ │ │ ├── _print_header.txt.erb │ │ │ ├── _print_statistics_tax.txt.erb │ │ │ ├── _print_statistics_category.txt.erb │ │ │ ├── _print_statistics_statistic_category.txt.erb │ │ │ ├── _print_statistics_user.txt.erb │ │ │ ├── _print_statistics_weekday.txt.erb │ │ │ ├── _statistics_table.html.haml │ │ │ ├── _statistics_statistic_category.html.haml │ │ │ ├── _statistics_category.html.haml │ │ │ ├── _statistics_tax.html.haml │ │ │ └── _statistics_user.html.haml │ │ ├── articles │ │ │ ├── find.js.erb │ │ │ ├── change_scope.js.erb │ │ │ ├── listall.html.haml │ │ │ ├── _find.html.haml │ │ │ ├── _scope_list.html.haml │ │ │ ├── _ingredient.html.haml │ │ │ └── sort_index.html.haml │ │ ├── cameras │ │ │ ├── show.html.haml │ │ │ └── index.html.haml │ │ ├── items │ │ │ ├── _inline_svg.html.erb │ │ │ ├── edit.js.erb │ │ │ ├── rotate_tax.js.erb │ │ │ ├── show.svg.erb │ │ │ └── print.html.haml │ │ ├── settlements │ │ │ ├── open.html.haml │ │ │ ├── create.js.erb │ │ │ ├── update.js.erb │ │ │ ├── edit.html.haml │ │ │ ├── detailed_list.html.haml │ │ │ └── index.html.haml │ │ ├── user_mailer │ │ │ └── technician_message.text.erb │ │ ├── layouts │ │ │ ├── _fonts.css.erb │ │ │ └── iframe.html.haml │ │ ├── tables │ │ │ └── index.html.haml │ │ ├── translations │ │ │ └── index.html.haml │ │ ├── bookings │ │ │ └── _totals_list.html.haml │ │ ├── presentations │ │ │ ├── show.html.haml │ │ │ └── index.html.haml │ │ ├── groups │ │ │ ├── new.html.haml │ │ │ └── index.html.haml │ │ ├── errors │ │ │ └── error.html.haml │ │ ├── shared │ │ │ └── _invoice_tax_list.html.haml │ │ ├── room_types │ │ │ ├── index.html.haml │ │ │ └── new.html.haml │ │ ├── payment_methods │ │ │ ├── index.html.haml │ │ │ └── new.html.haml │ │ ├── statistic_categories │ │ │ ├── index.html.haml │ │ │ └── new.html.haml │ │ ├── cost_centers │ │ │ ├── index.html.haml │ │ │ └── new.html.haml │ │ ├── rooms │ │ │ ├── index.html.haml │ │ │ └── new.html.haml │ │ ├── plugins │ │ │ └── index.html.haml │ │ ├── room_prices │ │ │ ├── new.html.haml │ │ │ └── index.html.haml │ │ ├── guest_types │ │ │ ├── index.html.haml │ │ │ └── new.html.haml │ │ ├── surcharges │ │ │ ├── _tax_amount.html.haml │ │ │ └── index.html.haml │ │ ├── seasons │ │ │ ├── index.html.haml │ │ │ └── new.html.haml │ │ ├── users │ │ │ ├── show.html.haml │ │ │ └── _logins_table.html.haml │ │ ├── taxes │ │ │ └── index.html.haml │ │ ├── options │ │ │ └── index.html.haml │ │ ├── stocks │ │ │ ├── new.html.haml │ │ │ └── index.html.haml │ │ └── roles │ │ │ └── index.html.haml │ ├── assets │ │ ├── stylesheets │ │ │ ├── invoice_cc.sass │ │ │ ├── mobile_special.sass │ │ │ ├── translations.css.scss │ │ │ ├── invoice_pl.sass │ │ │ └── iframe.sass │ │ ├── images │ │ │ ├── empty.png │ │ │ ├── key-bg.png │ │ │ ├── more.png │ │ │ ├── send.gif │ │ │ ├── body_bg.png │ │ │ ├── checkbox.png │ │ │ ├── customer.png │ │ │ ├── keyboard.png │ │ │ ├── ajax-loader.gif │ │ │ ├── client_logo.png │ │ │ ├── color_blank.png │ │ │ ├── color_blue.png │ │ │ ├── color_green.png │ │ │ ├── color_pink.png │ │ │ ├── drag_handle.png │ │ │ ├── keyboard-bg.png │ │ │ ├── red-e-tiny.png │ │ │ ├── ajax-loader2.gif │ │ │ ├── category_beer.png │ │ │ ├── category_fish.png │ │ │ ├── category_soup.png │ │ │ ├── category_tea.png │ │ │ ├── color_orange.png │ │ │ ├── color_violet.png │ │ │ ├── drag_handle3.png │ │ │ ├── app-billgastro.png │ │ │ ├── arrow_page_left.png │ │ │ ├── arrow_page_right.png │ │ │ ├── category_blank.png │ │ │ ├── category_coffee.png │ │ │ ├── category_dessert.png │ │ │ ├── category_noodles.png │ │ │ ├── category_pizza.png │ │ │ ├── category_salad.png │ │ │ ├── category_starter.png │ │ │ ├── category_teapot.png │ │ │ ├── button_mobile_back.png │ │ │ ├── button_mobile_cash.png │ │ │ ├── button_mobile_edit.png │ │ │ ├── button_mobile_exit.png │ │ │ ├── button_mobile_gear.png │ │ │ ├── button_mobile_next.png │ │ │ ├── button_mobile_plus.png │ │ │ ├── button_mobile_save.png │ │ │ ├── button_mobile_user.png │ │ │ ├── button_small_plus.png │ │ │ ├── category_aperitif.png │ │ │ ├── category_cigarette.png │ │ │ ├── category_customer.png │ │ │ ├── category_digestif.png │ │ │ ├── category_dmenucard.png │ │ │ ├── category_maindish.png │ │ │ ├── category_sidedish.png │ │ │ ├── category_sparkling.png │ │ │ ├── app-billgastro-update.png │ │ │ ├── button_mobile_cancel.png │ │ │ ├── button_mobile_check.png │ │ │ ├── button_mobile_clear.png │ │ │ ├── button_mobile_comment.png │ │ │ ├── button_mobile_delete.png │ │ │ ├── button_mobile_finish.png │ │ │ ├── button_mobile_invoice.png │ │ │ ├── button_mobile_login.png │ │ │ ├── button_mobile_minus.png │ │ │ ├── button_mobile_order.png │ │ │ ├── button_mobile_price.png │ │ │ ├── button_mobile_print1.png │ │ │ ├── button_mobile_print2.png │ │ │ ├── button_mobile_print3.png │ │ │ ├── button_mobile_refund.png │ │ │ ├── button_mobile_refund2.png │ │ │ ├── button_mobile_reload.png │ │ │ ├── button_mobile_room1.png │ │ │ ├── button_mobile_room2.png │ │ │ ├── button_mobile_room3.png │ │ │ ├── button_mobile_room4.png │ │ │ ├── button_mobile_scribe.png │ │ │ ├── button_mobile_tables.png │ │ │ ├── button_mobile_tables2.png │ │ │ ├── button_small_delete.png │ │ │ ├── category_childrendish.png │ │ │ ├── category_redwineglass.png │ │ │ ├── logo-small-billgastro.png │ │ │ ├── logo-tiny-billgastro.png │ │ │ ├── app-billgastro-support.png │ │ │ ├── button_mobile_invoices.png │ │ │ ├── button_mobile_previous.png │ │ │ ├── button_mobile_print_bar.png │ │ │ ├── button_mobile_scissors1.png │ │ │ ├── button_mobile_scissors2.png │ │ │ ├── button_mobile_scrollup.png │ │ │ ├── category_nonalcoholics.png │ │ │ ├── category_redwinebottle.png │ │ │ ├── category_rosewinebottle.png │ │ │ ├── category_rosewineglass.png │ │ │ ├── category_whitewineglass.png │ │ │ ├── button_mobile_cancel-small.png │ │ │ ├── button_mobile_cancel-tiny.png │ │ │ ├── button_mobile_fingerprint.png │ │ │ ├── button_mobile_finish-hand.png │ │ │ ├── button_mobile_finish-small.png │ │ │ ├── button_mobile_invoice_tilt.png │ │ │ ├── button_mobile_kitchenlist.png │ │ │ ├── button_mobile_last-invoice.png │ │ │ ├── button_mobile_print_chef.png │ │ │ ├── button_mobile_print_foods.png │ │ │ ├── button_mobile_print_tables.png │ │ │ ├── button_mobile_scrolldown.png │ │ │ ├── button_mobile_splitinvoice.png │ │ │ ├── button_mobile_user-arrow.png │ │ │ ├── category_whitewinebottle.png │ │ │ ├── logo-tiny-salorhospitality.png │ │ │ ├── button_mobile_last-invoice2.png │ │ │ ├── button_mobile_move-to-table.png │ │ │ ├── button_mobile_move-to-table2.png │ │ │ ├── logo-small-salorhospitality.png │ │ │ ├── button_mobile_finish-and-print.png │ │ │ ├── receipt-logo-footer-billgastro.png │ │ │ ├── receipt-logo-header-billgastro.png │ │ │ ├── receipt-logo-header-billgastro2.png │ │ │ ├── button_mobile_items_notifications.png │ │ │ ├── button_mobile_last-invoice-hotel.png │ │ │ ├── button_mobile_finish-and-print-hand.png │ │ │ └── icons │ │ │ │ ├── cost_center.svg │ │ │ │ ├── surcharge.svg │ │ │ │ ├── wallet.svg │ │ │ │ ├── help.svg │ │ │ │ └── statistic.svg │ │ └── javascripts │ │ │ ├── translations.js.coffee │ │ │ ├── menucard_iframe.js │ │ │ ├── hooks.js │ │ │ ├── dates.js │ │ │ ├── jquery-data.js │ │ │ ├── scrolling.js │ │ │ ├── orders-documentready.js │ │ │ ├── menucard_slideshow.js │ │ │ ├── audio.js │ │ │ ├── keyboard.js │ │ │ ├── translations.js │ │ │ └── application.js │ └── helpers │ │ ├── translations_helper.rb │ │ └── vendors_helper.rb ├── lib │ ├── assets │ │ └── .gitkeep │ ├── tasks │ │ ├── .gitkeep │ │ └── dbbackup.rake │ └── escper │ │ ├── escper │ │ ├── version.rb │ │ ├── log.rb │ │ ├── codepages.yml │ │ ├── vendor_printer.rb │ │ └── asciifier.rb │ │ └── escper.rb ├── public │ ├── assets │ │ └── .gitkeep │ ├── crossdomain.xml │ ├── send.gif │ ├── alert.mp3 │ ├── alert.wav │ ├── favicon.ico │ ├── company_logo.png │ ├── fonts │ │ ├── Rolina.ttf │ │ ├── Ubuntu-R.ttf │ │ └── aaaiight.ttf │ ├── images │ │ ├── empty.png │ │ ├── checkbox.png │ │ └── ajax-loader2.gif │ ├── mstile-70x70.png │ ├── favicon-16x16.png │ ├── favicon-32x32.png │ ├── favicon-96x96.png │ ├── mstile-144x144.png │ ├── mstile-150x150.png │ ├── mstile-310x150.png │ ├── mstile-310x310.png │ ├── apple-touch-icon.png │ ├── android-chrome-144x144.png │ ├── android-chrome-192x192.png │ ├── android-chrome-36x36.png │ ├── android-chrome-48x48.png │ ├── android-chrome-72x72.png │ ├── android-chrome-96x96.png │ ├── apple-touch-icon-57x57.png │ ├── apple-touch-icon-60x60.png │ ├── apple-touch-icon-72x72.png │ ├── apple-touch-icon-76x76.png │ ├── apple-touch-icon-114x114.png │ ├── apple-touch-icon-120x120.png │ ├── apple-touch-icon-144x144.png │ ├── apple-touch-icon-152x152.png │ ├── apple-touch-icon-180x180.png │ ├── apple-touch-icon-precomposed.png │ ├── robots.txt │ ├── browserconfig.xml │ ├── 422.html │ ├── 404.html │ ├── 500.html │ └── manifest.json ├── vendor │ └── assets │ │ ├── stylesheets │ │ └── .gitkeep │ │ └── javascripts │ │ ├── jquery.ui.datepicker-en.js │ │ ├── jquery.ui.datepicker-tr.js │ │ ├── jquery.ui.datepicker-gn.js │ │ ├── jquery.ui.datepicker-ru.js │ │ ├── jquery.ui.datepicker-pl.js │ │ ├── jquery.ui.datepicker-fr.js │ │ ├── jquery.ui.datepicker-es.js │ │ ├── jquery.ui.datepicker-it.js │ │ ├── jquery.ui.datepicker-el.js │ │ └── jquery.ui.datepicker-hu.js ├── spec │ ├── models │ │ ├── user_login_spec.rb │ │ └── user_messages_spec.rb │ ├── views │ │ └── translations │ │ │ └── edit.html.erb_spec.rb │ ├── controllers │ │ └── translations_controller_spec.rb │ ├── factories │ │ ├── user_logins.rb │ │ └── user_messages.rb │ └── helpers │ │ └── translations_helper_spec.rb ├── config │ ├── secrets.yml.example │ ├── environment.rb │ ├── boot.rb │ ├── database.yml.template │ ├── config.yml │ ├── nginx-site-http.template │ ├── nginx-site-https.template │ ├── initializers │ │ ├── hash.rb │ │ ├── inflections.rb │ │ ├── mime_types.rb │ │ ├── session_store.rb │ │ ├── wrap_parameters.rb │ │ └── escper.rb │ ├── database.yml.default │ └── codepages.yml ├── db │ └── migrate │ │ ├── 20150709085008_add_tpe_to_tax.rb │ │ ├── 20150529101946_add_cut_every_ticket_to_vendor_printers.rb │ │ ├── 20150624110801_add_print_quantity_reductions_to_vendors.rb │ │ ├── 20150612074929_add_one_ticket_per_piece_to_vendor_printers.rb │ │ ├── 20150908065754_create_plugins.rb │ │ ├── 20150709092033_create_item_types.rb │ │ ├── 20150906175346_drop_model_numbers.rb │ │ └── 20150709092112_add_item_types.rb ├── config.ru ├── doc │ └── README_FOR_APP ├── Rakefile ├── script │ └── rails └── Gemfile └── .gitignore /debian/conffiles: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /debian/compat: -------------------------------------------------------------------------------- 1 | 8 2 | -------------------------------------------------------------------------------- /debian/salor-hospitality.links: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /debian/salor-hospitality.manpages: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /salor-hospitality/log/.gitkeep: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /salor-hospitality/tmp/.gitkeep: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /debian/salor-hospitality.docs: -------------------------------------------------------------------------------- 1 | 2 | -------------------------------------------------------------------------------- /debian/source/format: -------------------------------------------------------------------------------- 1 | 3.0 (native) 2 | -------------------------------------------------------------------------------- /salor-hospitality/.rspec: -------------------------------------------------------------------------------- 1 | --colour 2 | -------------------------------------------------------------------------------- /salor-hospitality/app/mailers/.gitkeep: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /salor-hospitality/app/models/.gitkeep: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /salor-hospitality/lib/assets/.gitkeep: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /salor-hospitality/lib/tasks/.gitkeep: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /salor-hospitality/public/assets/.gitkeep: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /salor-hospitality/public/crossdomain.xml: -------------------------------------------------------------------------------- 1 | 2 | -------------------------------------------------------------------------------- /salor-hospitality/app/views/customers/show.html.haml: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /salor-hospitality/vendor/assets/stylesheets/.gitkeep: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /salor-hospitality/app/assets/stylesheets/invoice_cc.sass: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /salor-hospitality/app/views/orders/_customers.html.haml: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /debian/docs: -------------------------------------------------------------------------------- 1 | license.txt 2 | README~ 3 | README.md 4 | README.md~ 5 | -------------------------------------------------------------------------------- /salor-hospitality/app/views/orders/_functions_header_digital_menucard.html.haml: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /salor-hospitality/app/helpers/translations_helper.rb: -------------------------------------------------------------------------------- 1 | module TranslationsHelper 2 | end 3 | -------------------------------------------------------------------------------- /salor-hospitality/app/assets/stylesheets/mobile_special.sass: -------------------------------------------------------------------------------- 1 | div.item_list 2 | :font-size 150% -------------------------------------------------------------------------------- /salor-hospitality/lib/escper/escper/version.rb: -------------------------------------------------------------------------------- 1 | module Escper 2 | VERSION = "1.2.2" 3 | end 4 | -------------------------------------------------------------------------------- /salor-hospitality/app/views/exception_notifier/_backtrace.html.erb: -------------------------------------------------------------------------------- 1 | <%= raw @backtrace.join("\n") %> 2 | -------------------------------------------------------------------------------- /salor-hospitality/app/views/exception_notifier/_backtrace.text.erb: -------------------------------------------------------------------------------- 1 | <%= raw @backtrace.join("\n") %> 2 | -------------------------------------------------------------------------------- /salor-hospitality/app/views/exception_notifier/_data.html.erb: -------------------------------------------------------------------------------- 1 | * data: <%= raw PP.pp(@data, "") %> 2 | -------------------------------------------------------------------------------- /salor-hospitality/app/views/exception_notifier/_data.text.erb: -------------------------------------------------------------------------------- 1 | * data: <%= raw PP.pp(@data, "") %> 2 | -------------------------------------------------------------------------------- /salor-hospitality/app/views/vendors/edit.html.haml: -------------------------------------------------------------------------------- 1 | %h2= Vendor.model_name.human 2 | = render :partial => 'form' 3 | -------------------------------------------------------------------------------- /salor-hospitality/app/views/vendors/new.html.haml: -------------------------------------------------------------------------------- 1 | %h2= Vendor.model_name.human 2 | = render :partial => 'form' 3 | -------------------------------------------------------------------------------- /salor-hospitality/app/views/sessions/_screenlock.html.haml: -------------------------------------------------------------------------------- 1 | #screenlock 2 | = button_to '', session_path, :method => :delete -------------------------------------------------------------------------------- /salor-hospitality/app/views/partials/no_presentation_found.js.erb: -------------------------------------------------------------------------------- 1 | alert('<%= escape_javascript t '.no_presentations_found' %>'); 2 | -------------------------------------------------------------------------------- /salor-hospitality/public/send.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/public/send.gif -------------------------------------------------------------------------------- /salor-hospitality/app/views/pages/edit.html.haml: -------------------------------------------------------------------------------- 1 | = javascript_include_tag 'edit_page' 2 | 3 | %h2= t '.edit_page' 4 | = render 'form' 5 | -------------------------------------------------------------------------------- /salor-hospitality/app/views/pages/new.html.haml: -------------------------------------------------------------------------------- 1 | = javascript_include_tag 'edit_page' 2 | 3 | %h2= t '.new_page' 4 | = render 'form' 5 | -------------------------------------------------------------------------------- /salor-hospitality/public/alert.mp3: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/public/alert.mp3 -------------------------------------------------------------------------------- /salor-hospitality/public/alert.wav: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/public/alert.wav -------------------------------------------------------------------------------- /salor-hospitality/public/favicon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/public/favicon.ico -------------------------------------------------------------------------------- /salor-hospitality/app/views/statistics/_print_footer.txt.erb: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | <%= "\x1DV\x00\x0C" %> -------------------------------------------------------------------------------- /salor-hospitality/app/views/pages/find.js.erb: -------------------------------------------------------------------------------- 1 | $('#search_results').html('<%= escape_javascript render :partial => 'find', :layout => false %>'); 2 | -------------------------------------------------------------------------------- /salor-hospitality/public/company_logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/public/company_logo.png -------------------------------------------------------------------------------- /salor-hospitality/public/fonts/Rolina.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/public/fonts/Rolina.ttf -------------------------------------------------------------------------------- /salor-hospitality/public/images/empty.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/public/images/empty.png -------------------------------------------------------------------------------- /salor-hospitality/public/mstile-70x70.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/public/mstile-70x70.png -------------------------------------------------------------------------------- /salor-hospitality/app/views/articles/find.js.erb: -------------------------------------------------------------------------------- 1 | $('#search_results').html('<%= escape_javascript render :partial => 'find', :layout => false %>'); 2 | -------------------------------------------------------------------------------- /salor-hospitality/public/favicon-16x16.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/public/favicon-16x16.png -------------------------------------------------------------------------------- /salor-hospitality/public/favicon-32x32.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/public/favicon-32x32.png -------------------------------------------------------------------------------- /salor-hospitality/public/favicon-96x96.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/public/favicon-96x96.png -------------------------------------------------------------------------------- /salor-hospitality/public/fonts/Ubuntu-R.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/public/fonts/Ubuntu-R.ttf -------------------------------------------------------------------------------- /salor-hospitality/public/fonts/aaaiight.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/public/fonts/aaaiight.ttf -------------------------------------------------------------------------------- /salor-hospitality/public/mstile-144x144.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/public/mstile-144x144.png -------------------------------------------------------------------------------- /salor-hospitality/public/mstile-150x150.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/public/mstile-150x150.png -------------------------------------------------------------------------------- /salor-hospitality/public/mstile-310x150.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/public/mstile-310x150.png -------------------------------------------------------------------------------- /salor-hospitality/public/mstile-310x310.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/public/mstile-310x310.png -------------------------------------------------------------------------------- /debian/menu: -------------------------------------------------------------------------------- 1 | ?package(salor-hospitality):needs="X11" section="Applications/Office"\ 2 | title="SalorHospitality" command="/usr/bin/salor-hospitality" 3 | -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/empty.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/empty.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/key-bg.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/key-bg.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/more.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/more.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/send.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/send.gif -------------------------------------------------------------------------------- /salor-hospitality/app/views/cameras/show.html.haml: -------------------------------------------------------------------------------- 1 | %h2= @camera.name 2 | %p= @camera.description 3 | %img{ :src => @camera.resource(request.ip, 'stream') } -------------------------------------------------------------------------------- /salor-hospitality/public/apple-touch-icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/public/apple-touch-icon.png -------------------------------------------------------------------------------- /salor-hospitality/public/images/checkbox.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/public/images/checkbox.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/body_bg.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/body_bg.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/checkbox.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/checkbox.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/customer.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/customer.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/keyboard.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/keyboard.png -------------------------------------------------------------------------------- /salor-hospitality/public/images/ajax-loader2.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/public/images/ajax-loader2.gif -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/ajax-loader.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/ajax-loader.gif -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/client_logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/client_logo.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/color_blank.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/color_blank.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/color_blue.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/color_blue.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/color_green.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/color_green.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/color_pink.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/color_pink.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/drag_handle.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/drag_handle.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/keyboard-bg.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/keyboard-bg.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/red-e-tiny.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/red-e-tiny.png -------------------------------------------------------------------------------- /salor-hospitality/public/android-chrome-144x144.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/public/android-chrome-144x144.png -------------------------------------------------------------------------------- /salor-hospitality/public/android-chrome-192x192.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/public/android-chrome-192x192.png -------------------------------------------------------------------------------- /salor-hospitality/public/android-chrome-36x36.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/public/android-chrome-36x36.png -------------------------------------------------------------------------------- /salor-hospitality/public/android-chrome-48x48.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/public/android-chrome-48x48.png -------------------------------------------------------------------------------- /salor-hospitality/public/android-chrome-72x72.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/public/android-chrome-72x72.png -------------------------------------------------------------------------------- /salor-hospitality/public/android-chrome-96x96.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/public/android-chrome-96x96.png -------------------------------------------------------------------------------- /salor-hospitality/public/apple-touch-icon-57x57.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/public/apple-touch-icon-57x57.png -------------------------------------------------------------------------------- /salor-hospitality/public/apple-touch-icon-60x60.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/public/apple-touch-icon-60x60.png -------------------------------------------------------------------------------- /salor-hospitality/public/apple-touch-icon-72x72.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/public/apple-touch-icon-72x72.png -------------------------------------------------------------------------------- /salor-hospitality/public/apple-touch-icon-76x76.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/public/apple-touch-icon-76x76.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/ajax-loader2.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/ajax-loader2.gif -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/category_beer.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/category_beer.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/category_fish.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/category_fish.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/category_soup.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/category_soup.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/category_tea.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/category_tea.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/color_orange.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/color_orange.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/color_violet.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/color_violet.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/drag_handle3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/drag_handle3.png -------------------------------------------------------------------------------- /salor-hospitality/app/views/exception_notifier/_title.html.erb: -------------------------------------------------------------------------------- 1 | ------------------------------- 2 | <%= raw title.to_s.humanize %>: 3 | ------------------------------- 4 | -------------------------------------------------------------------------------- /salor-hospitality/app/views/exception_notifier/_title.text.erb: -------------------------------------------------------------------------------- 1 | ------------------------------- 2 | <%= raw title.to_s.humanize %>: 3 | ------------------------------- 4 | -------------------------------------------------------------------------------- /salor-hospitality/public/apple-touch-icon-114x114.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/public/apple-touch-icon-114x114.png -------------------------------------------------------------------------------- /salor-hospitality/public/apple-touch-icon-120x120.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/public/apple-touch-icon-120x120.png -------------------------------------------------------------------------------- /salor-hospitality/public/apple-touch-icon-144x144.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/public/apple-touch-icon-144x144.png -------------------------------------------------------------------------------- /salor-hospitality/public/apple-touch-icon-152x152.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/public/apple-touch-icon-152x152.png -------------------------------------------------------------------------------- /salor-hospitality/public/apple-touch-icon-180x180.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/public/apple-touch-icon-180x180.png -------------------------------------------------------------------------------- /debian/salor-hospitality.dirs: -------------------------------------------------------------------------------- 1 | /var/log/salor-hospitality 2 | /var/cache/salor-hospitality 3 | /usr/share/salor-hospitality/source/public/uploads 4 | /var/tmp/salor-hospitality -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/app-billgastro.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/app-billgastro.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/arrow_page_left.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/arrow_page_left.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/arrow_page_right.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/arrow_page_right.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/category_blank.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/category_blank.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/category_coffee.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/category_coffee.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/category_dessert.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/category_dessert.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/category_noodles.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/category_noodles.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/category_pizza.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/category_pizza.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/category_salad.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/category_salad.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/category_starter.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/category_starter.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/category_teapot.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/category_teapot.png -------------------------------------------------------------------------------- /salor-hospitality/spec/models/user_login_spec.rb: -------------------------------------------------------------------------------- 1 | require 'spec_helper' 2 | 3 | describe UserLogin do 4 | pending "add some examples to (or delete) #{__FILE__}" 5 | end 6 | -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/button_mobile_back.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/button_mobile_back.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/button_mobile_cash.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/button_mobile_cash.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/button_mobile_edit.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/button_mobile_edit.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/button_mobile_exit.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/button_mobile_exit.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/button_mobile_gear.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/button_mobile_gear.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/button_mobile_next.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/button_mobile_next.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/button_mobile_plus.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/button_mobile_plus.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/button_mobile_save.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/button_mobile_save.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/button_mobile_user.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/button_mobile_user.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/button_small_plus.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/button_small_plus.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/category_aperitif.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/category_aperitif.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/category_cigarette.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/category_cigarette.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/category_customer.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/category_customer.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/category_digestif.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/category_digestif.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/category_dmenucard.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/category_dmenucard.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/category_maindish.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/category_maindish.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/category_sidedish.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/category_sidedish.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/category_sparkling.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/category_sparkling.png -------------------------------------------------------------------------------- /salor-hospitality/config/secrets.yml.example: -------------------------------------------------------------------------------- 1 | development: 2 | secret_key_base: 3 | test: 4 | secret_key_base: 5 | production: 6 | secret_key_base: <%= ENV["SECRET_KEY_BASE"] %> -------------------------------------------------------------------------------- /salor-hospitality/public/apple-touch-icon-precomposed.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/public/apple-touch-icon-precomposed.png -------------------------------------------------------------------------------- /salor-hospitality/spec/models/user_messages_spec.rb: -------------------------------------------------------------------------------- 1 | require 'spec_helper' 2 | 3 | describe UserMessages do 4 | pending "add some examples to (or delete) #{__FILE__}" 5 | end 6 | -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/app-billgastro-update.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/app-billgastro-update.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/button_mobile_cancel.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/button_mobile_cancel.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/button_mobile_check.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/button_mobile_check.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/button_mobile_clear.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/button_mobile_clear.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/button_mobile_comment.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/button_mobile_comment.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/button_mobile_delete.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/button_mobile_delete.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/button_mobile_finish.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/button_mobile_finish.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/button_mobile_invoice.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/button_mobile_invoice.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/button_mobile_login.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/button_mobile_login.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/button_mobile_minus.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/button_mobile_minus.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/button_mobile_order.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/button_mobile_order.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/button_mobile_price.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/button_mobile_price.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/button_mobile_print1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/button_mobile_print1.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/button_mobile_print2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/button_mobile_print2.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/button_mobile_print3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/button_mobile_print3.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/button_mobile_refund.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/button_mobile_refund.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/button_mobile_refund2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/button_mobile_refund2.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/button_mobile_reload.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/button_mobile_reload.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/button_mobile_room1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/button_mobile_room1.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/button_mobile_room2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/button_mobile_room2.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/button_mobile_room3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/button_mobile_room3.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/button_mobile_room4.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/button_mobile_room4.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/button_mobile_scribe.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/button_mobile_scribe.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/button_mobile_tables.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/button_mobile_tables.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/button_mobile_tables2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/button_mobile_tables2.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/button_small_delete.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/button_small_delete.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/category_childrendish.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/category_childrendish.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/category_redwineglass.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/category_redwineglass.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/logo-small-billgastro.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/logo-small-billgastro.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/logo-tiny-billgastro.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/logo-tiny-billgastro.png -------------------------------------------------------------------------------- /salor-hospitality/app/models/email.rb: -------------------------------------------------------------------------------- 1 | class Email < ActiveRecord::Base 2 | include Scope 3 | include Base 4 | 5 | 6 | belongs_to :company 7 | belongs_to :vendor 8 | end 9 | -------------------------------------------------------------------------------- /salor-hospitality/app/views/pages/refresh.js.erb: -------------------------------------------------------------------------------- 1 | $('#page').html("<%= escape_javascript render :partial => 'page', :locals => { :page => @page, :partial_htmls => @partial_htmls } %>"); 2 | -------------------------------------------------------------------------------- /salor-hospitality/db/migrate/20150709085008_add_tpe_to_tax.rb: -------------------------------------------------------------------------------- 1 | class AddTpeToTax < ActiveRecord::Migration 2 | def change 3 | add_column :taxes, :tpe, :string 4 | end 5 | end 6 | -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/app-billgastro-support.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/app-billgastro-support.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/button_mobile_invoices.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/button_mobile_invoices.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/button_mobile_previous.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/button_mobile_previous.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/button_mobile_print_bar.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/button_mobile_print_bar.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/button_mobile_scissors1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/button_mobile_scissors1.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/button_mobile_scissors2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/button_mobile_scissors2.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/button_mobile_scrollup.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/button_mobile_scrollup.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/category_nonalcoholics.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/category_nonalcoholics.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/category_redwinebottle.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/category_redwinebottle.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/category_rosewinebottle.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/category_rosewinebottle.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/category_rosewineglass.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/category_rosewineglass.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/category_whitewineglass.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/category_whitewineglass.png -------------------------------------------------------------------------------- /salor-hospitality/app/views/items/_inline_svg.html.erb: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | -------------------------------------------------------------------------------- /salor-hospitality/app/views/settlements/open.html.haml: -------------------------------------------------------------------------------- 1 | %h1= t('activerecord.models.settlement.one') 2 | - @users.each do |u| 3 | = render :partial => 'settlement', :locals => { :u => u } 4 | -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/button_mobile_cancel-small.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/button_mobile_cancel-small.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/button_mobile_cancel-tiny.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/button_mobile_cancel-tiny.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/button_mobile_fingerprint.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/button_mobile_fingerprint.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/button_mobile_finish-hand.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/button_mobile_finish-hand.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/button_mobile_finish-small.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/button_mobile_finish-small.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/button_mobile_invoice_tilt.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/button_mobile_invoice_tilt.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/button_mobile_kitchenlist.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/button_mobile_kitchenlist.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/button_mobile_last-invoice.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/button_mobile_last-invoice.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/button_mobile_print_chef.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/button_mobile_print_chef.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/button_mobile_print_foods.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/button_mobile_print_foods.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/button_mobile_print_tables.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/button_mobile_print_tables.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/button_mobile_scrolldown.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/button_mobile_scrolldown.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/button_mobile_splitinvoice.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/button_mobile_splitinvoice.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/button_mobile_user-arrow.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/button_mobile_user-arrow.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/category_whitewinebottle.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/category_whitewinebottle.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/logo-tiny-salorhospitality.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/logo-tiny-salorhospitality.png -------------------------------------------------------------------------------- /salor-hospitality/app/views/items/edit.js.erb: -------------------------------------------------------------------------------- 1 | $('#invoice_<%= @order.id %>').replaceWith('<%= escape_javascript render :partial => 'orders/refund_form', :locals => { :order => @order } %>'); 2 | -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/button_mobile_last-invoice2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/button_mobile_last-invoice2.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/button_mobile_move-to-table.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/button_mobile_move-to-table.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/button_mobile_move-to-table2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/button_mobile_move-to-table2.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/logo-small-salorhospitality.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/logo-small-salorhospitality.png -------------------------------------------------------------------------------- /salor-hospitality/app/views/user_mailer/technician_message.text.erb: -------------------------------------------------------------------------------- 1 | IP: <%= @ip %> 2 | 3 | User Agent: <%= @useragent %> 4 | 5 | Timestamp: <%= Time.now %> 6 | 7 | Message: 8 | 9 | <%= raw @message %> -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/button_mobile_finish-and-print.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/button_mobile_finish-and-print.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/receipt-logo-footer-billgastro.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/receipt-logo-footer-billgastro.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/receipt-logo-header-billgastro.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/receipt-logo-header-billgastro.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/receipt-logo-header-billgastro2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/receipt-logo-header-billgastro2.png -------------------------------------------------------------------------------- /salor-hospitality/spec/views/translations/edit.html.erb_spec.rb: -------------------------------------------------------------------------------- 1 | require 'spec_helper' 2 | 3 | describe "translations/edit.html.erb" do 4 | pending "add some examples to (or delete) #{__FILE__}" 5 | end 6 | -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/button_mobile_items_notifications.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/button_mobile_items_notifications.png -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/button_mobile_last-invoice-hotel.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/button_mobile_last-invoice-hotel.png -------------------------------------------------------------------------------- /salor-hospitality/config.ru: -------------------------------------------------------------------------------- 1 | # This file is used by Rack-based servers to start the application. 2 | 3 | require ::File.expand_path('../config/environment', __FILE__) 4 | run SalorHospitality::Application 5 | -------------------------------------------------------------------------------- /debian/README: -------------------------------------------------------------------------------- 1 | The Debian Package salor-hospitality 2 | ---------------------------- 3 | 4 | Comments regarding the Package 5 | 6 | -- Michael Franzl Sat, 22 Sep 2012 16:19:01 +0200 7 | -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/button_mobile_finish-and-print-hand.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/michaelfranzl/SalorHospitality/HEAD/salor-hospitality/app/assets/images/button_mobile_finish-and-print-hand.png -------------------------------------------------------------------------------- /salor-hospitality/config/environment.rb: -------------------------------------------------------------------------------- 1 | # Load the rails application 2 | require File.expand_path('../application', __FILE__) 3 | 4 | # Initialize the rails application 5 | SalorHospitality::Application.initialize! 6 | -------------------------------------------------------------------------------- /salor-hospitality/app/views/orders/_note.haml: -------------------------------------------------------------------------------- 1 | %span.finish{ :onclick => "$('#note_for_order').slideUp();" } 2 | %input{ :id => 'order_note', :name => 'order[note]' } 3 | %span#order_note_display_keyboard.display_keyboard 4 | -------------------------------------------------------------------------------- /salor-hospitality/app/views/layouts/_fonts.css.erb: -------------------------------------------------------------------------------- 1 | <% SalorHospitality::Application::FONTS.each do |f| %> 2 | @font-face { 3 | font-family: <%= f %>; 4 | src: url('/fonts/<%= f %>.ttf') format("truetype"); 5 | } 6 | <% end %> 7 | -------------------------------------------------------------------------------- /salor-hospitality/config/boot.rb: -------------------------------------------------------------------------------- 1 | require 'rubygems' 2 | 3 | # Set up gems listed in the Gemfile. 4 | ENV['BUNDLE_GEMFILE'] ||= File.expand_path('../../Gemfile', __FILE__) 5 | 6 | require 'bundler/setup' if File.exists?(ENV['BUNDLE_GEMFILE']) -------------------------------------------------------------------------------- /salor-hospitality/app/models/item_type.rb: -------------------------------------------------------------------------------- 1 | class ItemType < ActiveRecord::Base 2 | include Scope 3 | include Base 4 | 5 | belongs_to :vendor 6 | belongs_to :company 7 | 8 | has_many :articles 9 | has_many :items 10 | end 11 | -------------------------------------------------------------------------------- /salor-hospitality/app/models/user_messages.rb: -------------------------------------------------------------------------------- 1 | class UserMessages < ActiveRecord::Base 2 | #attr_accessible :body, :company_id, :displayed, :hidden, :hidden_at, :hidden_by, :receipient_id, :reply_id, :sender_id, :subject, :type, :vendor_id 3 | end 4 | -------------------------------------------------------------------------------- /salor-hospitality/app/assets/stylesheets/translations.css.scss: -------------------------------------------------------------------------------- 1 | // Place all the styles related to the translations controller here. 2 | // They will automatically be included in application.css. 3 | // You can use Sass (SCSS) here: http://sass-lang.com/ 4 | -------------------------------------------------------------------------------- /salor-hospitality/db/migrate/20150529101946_add_cut_every_ticket_to_vendor_printers.rb: -------------------------------------------------------------------------------- 1 | class AddCutEveryTicketToVendorPrinters < ActiveRecord::Migration 2 | def change 3 | add_column :vendor_printers, :cut_every_ticket, :boolean 4 | end 5 | end 6 | -------------------------------------------------------------------------------- /salor-hospitality/db/migrate/20150624110801_add_print_quantity_reductions_to_vendors.rb: -------------------------------------------------------------------------------- 1 | class AddPrintQuantityReductionsToVendors < ActiveRecord::Migration 2 | def change 3 | add_column :vendors, :print_count_reductions, :boolean 4 | end 5 | end 6 | -------------------------------------------------------------------------------- /salor-hospitality/doc/README_FOR_APP: -------------------------------------------------------------------------------- 1 | Use this README file to introduce your application and point to useful places in the API for learning more. 2 | Run "rake doc:app" to generate API documentation for your models, controllers, helpers, and libraries. 3 | -------------------------------------------------------------------------------- /salor-hospitality/lib/escper/escper/log.rb: -------------------------------------------------------------------------------- 1 | module Escper 2 | def self.log(text) 3 | if defined?(ActiveRecord) 4 | ActiveRecord::Base.logger.info "[ESCPER] #{ text }" 5 | else 6 | puts "[ESCPER] #{ text }" 7 | end 8 | end 9 | end -------------------------------------------------------------------------------- /salor-hospitality/config/database.yml.template: -------------------------------------------------------------------------------- 1 | production: 2 | adapter: mysql2 3 | encoding: utf8 4 | reconnect: true 5 | database: _DBC_DBNAME_ 6 | username: _DBC_DBUSER_ 7 | password: '_DBC_DBPASS_' 8 | host: _DBC_DBSERVER_ 9 | port: _DBC_DBPORT_ -------------------------------------------------------------------------------- /salor-hospitality/public/robots.txt: -------------------------------------------------------------------------------- 1 | # See http://www.robotstxt.org/wc/norobots.html for documentation on how to use the robots.txt file 2 | # 3 | # To ban all spiders from the entire site uncomment the next two lines: 4 | # User-Agent: * 5 | # Disallow: / 6 | -------------------------------------------------------------------------------- /salor-hospitality/db/migrate/20150612074929_add_one_ticket_per_piece_to_vendor_printers.rb: -------------------------------------------------------------------------------- 1 | class AddOneTicketPerPieceToVendorPrinters < ActiveRecord::Migration 2 | def change 3 | add_column :vendor_printers, :one_ticket_per_piece, :boolean 4 | end 5 | end 6 | -------------------------------------------------------------------------------- /salor-hospitality/app/models/statistic_category.rb: -------------------------------------------------------------------------------- 1 | class StatisticCategory < ActiveRecord::Base 2 | include Scope 3 | include Base 4 | 5 | belongs_to :vendor 6 | belongs_to :company 7 | has_many :articles 8 | validates_presence_of :name 9 | end 10 | -------------------------------------------------------------------------------- /salor-hospitality/app/views/exception_notifier/_session.html.erb: -------------------------------------------------------------------------------- 1 | * session id: <%= @request.ssl? ? "[FILTERED]" : (raw (@request.session['session_id'] || @request.env["rack.session.options"][:id]).inspect.html_safe) %> 2 | * data: <%= raw PP.pp(@request.session, "") %> 3 | -------------------------------------------------------------------------------- /salor-hospitality/app/views/exception_notifier/_session.text.erb: -------------------------------------------------------------------------------- 1 | * session id: <%= @request.ssl? ? "[FILTERED]" : (raw (@request.session['session_id'] || @request.env["rack.session.options"][:id]).inspect.html_safe) %> 2 | * data: <%= raw @request.session.inspect %> 3 | -------------------------------------------------------------------------------- /salor-hospitality/app/views/orders/_functions_header_last_invoices.html.haml: -------------------------------------------------------------------------------- 1 | %a.iconbutton.next_button{ :onclick => "route('tables');", :title => t(:cancel_and_go_back) } 2 | %a.iconbutton.scrolldown_button{ :onclick => "scroll_to('#footer')", :title => t(:scroll_down) } 3 | -------------------------------------------------------------------------------- /debian/README.source: -------------------------------------------------------------------------------- 1 | salor-hospitality for Debian 2 | ---------------------------- 3 | 4 | 6 | 7 | 8 | 9 | 10 | -------------------------------------------------------------------------------- /salor-hospitality/app/views/settlements/create.js.erb: -------------------------------------------------------------------------------- 1 | $('#user_<%= @settlement.user.id %>').replaceWith('<%= escape_javascript render(:partial => 'settlement', :locals => { :u => @settlement.user }) %>'); 2 | $('#user_<%= @settlement.user.id %>').effect("highlight", {}, 1000); 3 | -------------------------------------------------------------------------------- /salor-hospitality/app/views/settlements/update.js.erb: -------------------------------------------------------------------------------- 1 | $('#user_<%= @settlement.user.id %>').replaceWith('<%= escape_javascript render(:partial => 'settlement', :locals => { :u => @settlement.user }) %>'); 2 | $('#user_<%= @settlement.user.id %>').effect("highlight", {}, 1000); 3 | -------------------------------------------------------------------------------- /debian/salor-hospitality.cron.d: -------------------------------------------------------------------------------- 1 | # 2 | # Regular cron jobs for the salor-hospitality package 3 | # 4 | 0 2 * * * root test -x /usr/bin/salor-maintenance && /usr/bin/salor-maintenance h 5 | 0 3 * * * root test -x /usr/bin/salor-remote-backup && /usr/bin/salor-remote-backup h 6 | 7 | 8 | -------------------------------------------------------------------------------- /salor-hospitality/app/views/partials/create.js.erb: -------------------------------------------------------------------------------- 1 | $('#page_<%= @page.id %>').append('<%= escape_javascript render :partial => 'edit_partial', :locals => { :partial => @partial, :markup => @partial_html, :model_id => @model_id, :presentations => @presentations } %>'); 2 | set_handles(); 3 | -------------------------------------------------------------------------------- /salor-hospitality/config/config.yml: -------------------------------------------------------------------------------- 1 | --- 2 | :exception_notification: false 3 | :exception_notification_sender: Sender Name 4 | :exception_notification_receipients: nobody@localhost 5 | :use_safe_device_path: false 6 | :tailor: false 7 | :history: true 8 | :receipt_history: true -------------------------------------------------------------------------------- /salor-hospitality/app/views/exception_notifier/_request.html.erb: -------------------------------------------------------------------------------- 1 | * URL : <%= raw @request.url %> 2 | * IP address: <%= raw @request.remote_ip %> 3 | * Parameters: <%= raw @request.filtered_parameters.inspect %> 4 | * Rails root: <%= raw Rails.root %> 5 | * Timestamp : <%= raw Time.current %> 6 | -------------------------------------------------------------------------------- /salor-hospitality/app/views/exception_notifier/_request.text.erb: -------------------------------------------------------------------------------- 1 | * URL : <%= raw @request.url %> 2 | * IP address: <%= raw @request.remote_ip %> 3 | * Parameters: <%= raw @request.filtered_parameters.inspect %> 4 | * Rails root: <%= raw Rails.root %> 5 | * Timestamp : <%= raw Time.current %> 6 | -------------------------------------------------------------------------------- /salor-hospitality/app/views/partials/update.js.erb: -------------------------------------------------------------------------------- 1 | $("#partial_<%= @partial.id %>").replaceWith('<%= escape_javascript render :partial => 'edit_partial', :locals => { :partial => @partial, :markup => @partial_html, :model_id => @model_id, :presentations => @presentations } %>'); 2 | set_handles(); 3 | -------------------------------------------------------------------------------- /salor-hospitality/app/assets/javascripts/translations.js.coffee: -------------------------------------------------------------------------------- 1 | # Place all the behaviors and hooks related to the matching controller here. 2 | # All this logic will automatically be available in application.js. 3 | # You can use CoffeeScript in this file: http://jashkenas.github.com/coffee-script/ 4 | -------------------------------------------------------------------------------- /salor-hospitality/spec/controllers/translations_controller_spec.rb: -------------------------------------------------------------------------------- 1 | require 'spec_helper' 2 | 3 | describe TranslationsController do 4 | 5 | describe "GET 'edit'" do 6 | it "returns http success" do 7 | get 'edit' 8 | response.should be_success 9 | end 10 | end 11 | 12 | end 13 | -------------------------------------------------------------------------------- /salor-hospitality/app/views/tables/index.html.haml: -------------------------------------------------------------------------------- 1 | %h2= t('activerecord.models.table.other') 2 | 3 | %p 4 | = link_to(t(:new), new_table_path, :class => 'links') 5 | 6 | #table_index 7 | - @tables.each do |ta| 8 | = link_to edit_table_path(ta), :class => 'table_links' do 9 | %div.table_index= ta.name 10 | -------------------------------------------------------------------------------- /salor-hospitality/Rakefile: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env rake 2 | # Add your own tasks in files placed in lib/tasks ending in .rake, 3 | # for example lib/tasks/capistrano.rake, and they will automatically be available to Rake. 4 | 5 | require File.expand_path('../config/application', __FILE__) 6 | 7 | SalorHospitality::Application.load_tasks 8 | -------------------------------------------------------------------------------- /debian/bin/salor-hospitality.desktop: -------------------------------------------------------------------------------- 1 | [Desktop Entry] 2 | Type=Application 3 | Version=1.0 4 | Name=Salor Hospitality Point Of Sale 5 | GenericName=Salor Hospitality Point Of Sale 6 | Icon=salor-hospitality-icon 7 | Exec=salor-hospitality 8 | Terminal=false 9 | Categories=GNOME;Office; 10 | Encoding=UTF-8 11 | Name[de]=Salor Hospitality 12 | -------------------------------------------------------------------------------- /salor-hospitality/app/views/items/rotate_tax.js.erb: -------------------------------------------------------------------------------- 1 | $('#order_<%= @item.order.id %>_item_<%= @item.id %>').css('backgroundColor', '<%= @current_vendor.taxes.find_by_id(@item.taxes.keys.first).color %>'); 2 | $('#order_<%= @item.order.id %>_item_<%= @item.id %> .count').html('<%= @current_vendor.taxes.find_by_id(@item.taxes.keys.first).letter %>'); 3 | -------------------------------------------------------------------------------- /salor-hospitality/config/nginx-site-http.template: -------------------------------------------------------------------------------- 1 | server { 2 | listen 80; 3 | server_name INSTANCE_ID.sh.localhost; 4 | root /usr/share/salor-hospitality/INSTANCE_ID/public; 5 | passenger_enabled on; 6 | passenger_env_var SH_DEBIAN_SITEID INSTANCE_ID; 7 | passenger_env_var BUNDLE_GEMFILE /etc/salor-hospitality/INSTANCE_ID/Gemfile; 8 | } -------------------------------------------------------------------------------- /salor-hospitality/script/rails: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env ruby 2 | # This command will automatically be run when you run "rails" with Rails 3 gems installed from the root of your application. 3 | 4 | APP_PATH = File.expand_path('../../config/application', __FILE__) 5 | require File.expand_path('../../config/boot', __FILE__) 6 | require 'rails/commands' 7 | -------------------------------------------------------------------------------- /salor-hospitality/config/nginx-site-https.template: -------------------------------------------------------------------------------- 1 | server { 2 | listen 443 ssl; 3 | server_name INSTANCE_ID.sh.localhost; 4 | root /usr/share/salor-hospitality/INSTANCE_ID/public; 5 | passenger_enabled on; 6 | passenger_env_var SH_DEBIAN_SITEID INSTANCE_ID; 7 | passenger_env_var BUNDLE_GEMFILE /etc/salor-hospitality/INSTANCE_ID/Gemfile; 8 | } -------------------------------------------------------------------------------- /salor-hospitality/app/views/translations/index.html.haml: -------------------------------------------------------------------------------- 1 | = javascript_include_tag 'translations' 2 | 3 | %h2= t('various.translations') 4 | 5 | %ul#translation_form 6 | 7 | 8 | :javascript 9 | var translation = #{ @translation }; 10 | var translation_file = '#{ params[:f] }'; 11 | render_translation_inputs(0, [], translation, $('#translation_form')); -------------------------------------------------------------------------------- /salor-hospitality/app/views/articles/change_scope.js.erb: -------------------------------------------------------------------------------- 1 | <% if @source %> 2 | $('#<%= @source %>_list').html('<%= escape_javascript render :partial => 'scope_list', :locals => { :scope => @source } %>'); 3 | <% end %> 4 | 5 | <% if @target %> 6 | $('#<%= @target %>_list').html('<%= escape_javascript render :partial => 'scope_list', :locals => { :scope => @target } %>'); 7 | <% end %> 8 | -------------------------------------------------------------------------------- /salor-hospitality/app/views/pages/_page.html.haml: -------------------------------------------------------------------------------- 1 | - partial = controller.action_name == 'edit' ? '/partials/edit_partial' : '/partials/simple_partial' 2 | - page.partials.each do |par| 3 | = render :partial => partial, :locals => { :partial => par, :markup => partial_htmls[par.id], :model_id => par.model_id, :presentations => Presentation.existing.where(:model => par.presentation.model) } 4 | -------------------------------------------------------------------------------- /salor-hospitality/config/initializers/hash.rb: -------------------------------------------------------------------------------- 1 | class Hash 2 | def replace_nested_value_by(keys, value) 3 | if keys.size > 1 4 | #puts "recursion" 5 | self[keys.first].replace_nested_value_by(keys[1..-1], value) 6 | elsif keys.size == 1 7 | #puts "setting #{ keys.inspect} to #{ value.inspect}" 8 | self[keys.first] = value 9 | end 10 | end 11 | end -------------------------------------------------------------------------------- /salor-hospitality/app/views/bookings/_totals_list.html.haml: -------------------------------------------------------------------------------- 1 | %table.booking_totals 2 | %tr.total 3 | %td= Booking.model_name.human 4 | %td#booking_total 5 | - booking.orders.each do |o| 6 | %tr 7 | %td= "#{ Order.model_name.human } ID #{ o.id }" 8 | %td= number_to_currency o.sum 9 | %tr.subtotal 10 | %td= t 'various.subtotal' 11 | %td#booking_subtotal 12 | -------------------------------------------------------------------------------- /salor-hospitality/app/views/exception_notifier/_salor.text.erb: -------------------------------------------------------------------------------- 1 | SalorHospitality <%= SalorHospitality::Application::VERSION %> 2 | 3 | <% user = User.find_by_id(@request.session[:user_id]) %> 4 | <% vendor = Vendor.find_by_id(@request.session[:vendor_id]) %> 5 | 6 | Company: <%= user.company.name if user %> 7 | 8 | Vendor: <%= vendor.name if vendor %> 9 | 10 | User: <%= user.login if user %> 11 | -------------------------------------------------------------------------------- /salor-hospitality/app/views/orders/_functions_header_invoice_form.html.haml: -------------------------------------------------------------------------------- 1 | - if workstation? 2 | %a.iconbutton.scrollup_button{ :onclick => 'scroll_for(-200,20)', :title => t(:scroll_up) } 3 | 4 | %a.iconbutton.back_button{ :onclick => "route('tables');", :title => t(:cancel_and_go_back) } 5 | 6 | - if workstation? 7 | %a.iconbutton.scrolldown_button{ :onclick => 'scroll_for(200,20)', :title => t(:scroll_down) } 8 | -------------------------------------------------------------------------------- /salor-hospitality/app/views/orders/render_invoice_form.js.erb: -------------------------------------------------------------------------------- 1 | if (invoice_update == true) { 2 | route('invoice'); 3 | $('#invoices').html('<%= escape_javascript render :partial => 'orders/invoice_form', :collection => @orders %>'); 4 | } 5 | submit_json.split_items_hash.original = <%= @orders.first ? @orders.first.id : 'null' %>; 6 | submit_json.split_items_hash.partner = <%= @orders.last ? @orders.last.id : 'null' %>; -------------------------------------------------------------------------------- /salor-hospitality/app/views/statistics/_print_statistics_sold_quantities.txt.erb: -------------------------------------------------------------------------------- 1 | 2 | 3 | <%= "\e!\x38" %> 4 | <%= I18n.t('various.sold_quantities') %> 5 | 6 | <%= "\e!\x00" %> 7 | <% @data.each do |id, data| %> 8 | <% next if data[:count].zero? %> 9 | <%= "%s %21.21s %s %7.2f %5i\n" % [data[:tax_letter], data[:full_name], @friendly_unit, data[:sum], data[:count]] %> 10 | <% end %> 11 | 12 | <%= "\xc4" * 42 %> -------------------------------------------------------------------------------- /salor-hospitality/app/views/exception_notifier/_environment.html.erb: -------------------------------------------------------------------------------- 1 | <% filtered_env = @request.filtered_env -%> 2 | <% max = filtered_env.keys.map(&:to_s).max { |a, b| a.length <=> b.length } -%> 3 | <% filtered_env.keys.map(&:to_s).sort.each do |key| -%> 4 | * <%= raw("%-*s: %s" % [max.length, key, inspect_object(filtered_env[key])]) %> 5 | <% end -%> 6 | 7 | * Process: <%= raw $$ %> 8 | * Server : <%= raw `hostname`.chomp %> 9 | -------------------------------------------------------------------------------- /salor-hospitality/app/views/exception_notifier/_environment.text.erb: -------------------------------------------------------------------------------- 1 | <% filtered_env = @request.filtered_env -%> 2 | <% max = filtered_env.keys.map(&:to_s).max { |a, b| a.length <=> b.length } -%> 3 | <% filtered_env.keys.map(&:to_s).sort.each do |key| -%> 4 | * <%= raw("%-*s: %s" % [max.length, key, inspect_object(filtered_env[key])]) %> 5 | <% end -%> 6 | 7 | * Process: <%= raw $$ %> 8 | * Server : <%= raw `hostname`.chomp %> 9 | -------------------------------------------------------------------------------- /salor-hospitality/app/views/presentations/show.html.haml: -------------------------------------------------------------------------------- 1 | %h2= @user.login 2 | 3 | %p== Rolle: #{ @user.role } 4 | 5 | %table{ :class => 'settlements' } 6 | - sum = 0 7 | - @user.settlements.each do |s| 8 | %tr 9 | %td{ :style => 'width:220px' }= l s.created_at, :format => :datetime_iso 10 | %td{ :style => 'width:120px' }= link_to("#{ Settlement.model_name.human } ##{s.id}", user_settlement_path(@user,s)) 11 | -------------------------------------------------------------------------------- /salor-hospitality/app/assets/stylesheets/invoice_pl.sass: -------------------------------------------------------------------------------- 1 | div.paper_invoice 2 | h1 3 | :text-align center 4 | 5 | div.customer_details 6 | :float right 7 | :text-align right 8 | 9 | div.vendor_details 10 | :float left 11 | :text-align left 12 | 13 | p.date 14 | :float right 15 | 16 | select.original_copy 17 | :float right 18 | :border none 19 | :background-color transparent -------------------------------------------------------------------------------- /salor-hospitality/app/views/statistics/_print_header.txt.erb: -------------------------------------------------------------------------------- 1 | <%= "\e@" %> 2 | <%= I18n.l @from, :format => :date_iso %> -> <%= I18n.l @to, :format => :date_iso %> 3 | 4 | <%= I18n.t('activerecord.models.cost_center.one') %>: <%= @selected_cost_center ? @selected_cost_center.name : I18n.t('settlements.index.all') %> 5 | 6 | <%= I18n.t('activerecord.models.user.one') %>: <%= @selected_user ? @selected_user.login : I18n.t('settlements.index.all') %> -------------------------------------------------------------------------------- /salor-hospitality/app/views/articles/listall.html.haml: -------------------------------------------------------------------------------- 1 | %h2= t '.all_articles' 2 | 3 | - @articles.each do |ar| 4 | %div.articles_listall 5 | %span.name== #{ link_to ar.name, edit_article_path(ar) } 6 | %span.price= number_to_currency ar.price if ar.quantities.empty? 7 | %br 8 | - ar.quantities.each do |qu| 9 | %span.name== #{qu.prefix}, #{qu.postfix} 10 | %span.price= number_to_currency qu.price 11 | %br 12 | -------------------------------------------------------------------------------- /salor-hospitality/app/views/items/show.svg.erb: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /salor-hospitality/app/views/pages/_pages.html.haml: -------------------------------------------------------------------------------- 1 | - pages.each do |p| 2 | - partial_htmls = partial_htmls_pages[p.id] 3 | - background_image = "background-image: url('#{ p.image }');" if p.image 4 | .page{ :id => "page_#{ p.id }", :style => "width: #{ p.width }px; height: #{ p.height }px; #{ background_image } background-color: #{ p.color };"} 5 | = render :partial => '/pages/page', :locals => { :page => p, :partial_htmls => partial_htmls } -------------------------------------------------------------------------------- /salor-hospitality/app/views/groups/new.html.haml: -------------------------------------------------------------------------------- 1 | %h2= @cost_center.new_record? ? (t '.new_group') : (t '.edit_group') 2 | 3 | = error_messages_for 'group' 4 | 5 | - form_for @group do |group_form| 6 | %table 7 | %tr 8 | %td 9 | = group_form.label('name', Group.human_attribute_name(:name)) 10 | %td 11 | = group_form.text_field :name 12 | 13 | %p= submit_tag( controller.action_name == 'new' ? (t :create) : (t :edit) ) 14 | -------------------------------------------------------------------------------- /salor-hospitality/config/initializers/inflections.rb: -------------------------------------------------------------------------------- 1 | # Be sure to restart your server when you modify this file. 2 | 3 | # Add new inflection rules using the following format 4 | # (all these examples are active by default): 5 | ActiveSupport::Inflector.inflections do |inflect| 6 | # inflect.plural /^(ox)$/i, '\1en' 7 | # inflect.singular /^(ox)en/i, '\1' 8 | inflect.irregular 'tax', 'taxes' 9 | # inflect.uncountable %w( fish sheep ) 10 | end 11 | -------------------------------------------------------------------------------- /salor-hospitality/app/views/customers/index.csv.erb: -------------------------------------------------------------------------------- 1 | <%= "id;first_name;last_name;company_name;address;city;state;country;postalcode;m_number;m_points;email;telephone;cellphone" %> 2 | <% @current_company.customers.existing.each do |i| -%> 3 | <%= sprintf('%u;%s;%s;%s;%s;%s;%s;%s;%s;%s;%s;%s;%s;%s;', i.id, i.first_name, i.last_name, i.company_name, i.address, i.city, i.state, i.country, i.postalcode, i.m_number, i.m_points, i.email, i.telephone, i.cellphone) %> 4 | <% end -%> 5 | -------------------------------------------------------------------------------- /salor-hospitality/config/initializers/mime_types.rb: -------------------------------------------------------------------------------- 1 | # Be sure to restart your server when you modify this file. 2 | 3 | # Add new mime types for use in respond_to blocks: 4 | # Mime::Type.register "text/richtext", :rtf 5 | # Mime::Type.register_alias "text/html", :iphone 6 | Mime::Type.register "application/vnd.print", :bill 7 | Mime::Type.register "text/plain", :sql 8 | Mime::Type.register "application/x-font-ttf", :ttf 9 | Mime::Type.register "image/svg+xml", :svg 10 | -------------------------------------------------------------------------------- /salor-hospitality/app/views/partials/_simple_partial.html.haml: -------------------------------------------------------------------------------- 1 | :css 2 | div#partial_#{ partial.id } img { width: #{ partial.image_size || 0 }px; } 3 | div#partial_#{ partial.id } { color: #{ partial.color } } 4 | 5 | .partial{ :id => "partial_#{ partial.id }", :style => "left: #{ partial.left }px; top: #{ partial.top }px", :left_orig => partial.left, :top_orig => partial.top } 6 | %span{ :style => "font-size: #{ partial.size }%; font-family: #{ partial.font };" }= raw markup 7 | -------------------------------------------------------------------------------- /salor-hospitality/lib/escper/escper/codepages.yml: -------------------------------------------------------------------------------- 1 | --- 2 | # Codepage 0 corresponds to the codepage 0 of Metapace T family of thermal printers 3 | 0: 4 | ä: 0x84 5 | ü: 0x81 6 | ö: 0x94 7 | Ä: 0x8E 8 | Ü: 0x9A 9 | Ö: 0x99 10 | é: 0x82 11 | è: 0x8A 12 | ú: 0xA3 13 | ù: 0x97 14 | á: 0xA0 15 | à: 0x85 16 | í: 0xA1 17 | ì: 0x8D 18 | ó: 0xA2 19 | ò: 0x95 20 | â: 0x83 21 | ê: 0x88 22 | î: 0x8C 23 | ô: 0x93 24 | û: 0x96 25 | ñ: 0xA4 26 | ß: 0xE1 -------------------------------------------------------------------------------- /salor-hospitality/app/views/pages/index.html.haml: -------------------------------------------------------------------------------- 1 | = javascript_include_tag 'menucard_slideshow.js' 2 | 3 | - if @current_user 4 | = link_to (t :new), new_page_path, :class => 'links' 5 | - @pages.each do |p| 6 | = link_to edit_page_path(p) do 7 | %span.button=p.id 8 | 9 | = render :partial => 'pages', :locals => {:pages => @pages, :partial_htmls_pages => @partial_htmls_pages} 10 | 11 | :javascript 12 | var page_count = #{ @pages.count }; 13 | var page_ids = #{ @pages_ids.to_s }; -------------------------------------------------------------------------------- /salor-hospitality/config/initializers/session_store.rb: -------------------------------------------------------------------------------- 1 | # Be sure to restart your server when you modify this file. 2 | 3 | SalorHospitality::Application.config.session_store :cookie_store, key: '_SalorHospitality_session' 4 | 5 | # Use the database for sessions instead of the cookie-based default, 6 | # which shouldn't be used to store highly confidential information 7 | # (create the session table with "rails generate session_migration") 8 | # BillGastro::Application.config.session_store :active_record_store 9 | -------------------------------------------------------------------------------- /salor-hospitality/lib/tasks/dbbackup.rake: -------------------------------------------------------------------------------- 1 | namespace :db do 2 | desc "Backup the database to public/backup.sql" 3 | task :backup do 4 | dbconfig = YAML::load(File.open('config/database.yml')) 5 | mode = ENV['RAILS_ENV'] ? ENV['RAILS_ENV'] : 'development' 6 | username = dbconfig[mode]['username'] 7 | password = dbconfig[mode]['password'] 8 | database = dbconfig[mode]['database'] 9 | `mysqldump -u #{username} -p#{password} #{database} > public/backup.sql` 10 | end 11 | end 12 | -------------------------------------------------------------------------------- /salor-hospitality/spec/factories/user_logins.rb: -------------------------------------------------------------------------------- 1 | # Read about factories at https://github.com/thoughtbot/factory_girl 2 | 3 | FactoryGirl.define do 4 | factory :user_login do 5 | company_id 1 6 | vendor_id 1 7 | user_id 1 8 | login "2013-07-24 10:28:17" 9 | logout "2013-07-24 10:28:17" 10 | duration 1 11 | hourly_rate 1.5 12 | hidden false 13 | hidden_by 1 14 | hidden_at "2013-07-24 10:28:17" 15 | ip "MyString" 16 | auto_logout false 17 | end 18 | end 19 | -------------------------------------------------------------------------------- /salor-hospitality/spec/factories/user_messages.rb: -------------------------------------------------------------------------------- 1 | # Read about factories at https://github.com/thoughtbot/factory_girl 2 | 3 | FactoryGirl.define do 4 | factory :user_message, :class => 'UserMessages' do 5 | sender_id 1 6 | receipient_id 1 7 | reply_id 1 8 | displayed false 9 | subject "MyString" 10 | body "MyText" 11 | type "" 12 | vendor_id 1 13 | company_id 1 14 | hidden false 15 | hidden_by 1 16 | hidden_at "2013-08-31 09:34:17" 17 | end 18 | end 19 | -------------------------------------------------------------------------------- /salor-hospitality/app/mailers/user_mailer.rb: -------------------------------------------------------------------------------- 1 | class UserMailer < ActionMailer::Base 2 | default from: "#{SalorHospitality::Application::SH_DEBIAN_SITEID}.sh@#{ `hostname`.strip }" 3 | 4 | def technician_message(vendor, subject, msg='', request=nil) 5 | if request 6 | @ip = request.remote_ip 7 | @useragent = request.env['HTTP_USER_AGENT'] 8 | end 9 | @message = msg 10 | mail(:to => vendor.technician_email, :subject => "[SalorHospitalityMessage #{ vendor.name }] #{ subject }") 11 | end 12 | end -------------------------------------------------------------------------------- /salor-hospitality/app/views/items/print.html.haml: -------------------------------------------------------------------------------- 1 | %h2= t('activerecord.models.item.other') 2 | 3 | %table 4 | %tr 5 | %th{ :width => '100px' } 6 | %th{ :width => '200px' } 7 | %th{ :width => '120px' } 8 | %th{ :width => '120px' } 9 | - @unprinted_items.each do |ui| 10 | - next if ui.article.category.tax.percent != 10 # This is ugly but works for now 11 | %tr 12 | %td= ui.order.user.title 13 | %td= ui.order.table.name 14 | %td= ui.count 15 | %td= ui.article.name.upcase 16 | -------------------------------------------------------------------------------- /salor-hospitality/public/browserconfig.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | #ffc40d 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /debian/bin/salor-hospitality: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | if [ -e /usr/bin/salor-bin ]; then 4 | echo "Loading salor-bin. Please wait..." 5 | gksu "salor-bin -u http://default.sh.localhost" 6 | 7 | elif [ -e /usr/bin/chromium-browser ]; then 8 | echo "Loading Chromium in Kiosk mode. Please wait..." 9 | chromium-browser --kiosk --incognito -start-maximized http://default.sh.localhost 10 | 11 | elif [ -e /usr/bin/firefox ]; then 12 | echo "Loading Firefox. Please wait..." 13 | firefox http://default.sh.localhost 14 | 15 | fi 16 | -------------------------------------------------------------------------------- /salor-hospitality/app/views/errors/error.html.haml: -------------------------------------------------------------------------------- 1 | .error_page 2 | %h1= I18n.t('various.exception_page.oops_an_error_occurred') 3 | %br 4 | %br 5 | %b= t('various.exception_page.assistance_text') 6 | %br 7 | %br 8 | %a.links{ :href => '/' } HOME 9 | %br 10 | %br 11 | %br 12 | .errordescription 13 | %h2= t('various.exception_page.exception_description') 14 | %p= @exception.message 15 | %h2= t('various.exception_page.exception_in_files') 16 | %small= raw @exception.backtrace[0..3].join('
') 17 | -------------------------------------------------------------------------------- /salor-hospitality/app/assets/javascripts/menucard_iframe.js: -------------------------------------------------------------------------------- 1 | var ran_documentready_menucard_iframe = false; 2 | 3 | $(function() { 4 | if (ran_documentready_menucard_iframe == true) return; 5 | 6 | $(window).bind('resize', function() { 7 | var display_height = $(window).height(); 8 | var display_width = $(window).width(); 9 | //console.log('inside menucard_iframe documentready'); 10 | page_resize(display_width, display_height); 11 | }).trigger('resize'); 12 | 13 | ran_documentready_menucard_iframe = true; 14 | }) -------------------------------------------------------------------------------- /salor-hospitality/db/migrate/20150908065754_create_plugins.rb: -------------------------------------------------------------------------------- 1 | class CreatePlugins < ActiveRecord::Migration 2 | def change 3 | create_table :plugins do |t| 4 | t.string :name 5 | t.string :filename 6 | t.string :base_path 7 | t.text :files 8 | t.text :meta 9 | t.integer :company_id 10 | t.integer :vendor_id 11 | t.integer :user_id 12 | t.boolean :hidden 13 | t.integer :hidden_by 14 | t.datetime :hidden_at 15 | 16 | t.timestamps 17 | end 18 | end 19 | end 20 | -------------------------------------------------------------------------------- /salor-hospitality/spec/helpers/translations_helper_spec.rb: -------------------------------------------------------------------------------- 1 | require 'spec_helper' 2 | 3 | # Specs in this file have access to a helper object that includes 4 | # the TranslationsHelper. For example: 5 | # 6 | # describe TranslationsHelper do 7 | # describe "string concat" do 8 | # it "concats two strings with spaces" do 9 | # helper.concat_strings("this","that").should == "this that" 10 | # end 11 | # end 12 | # end 13 | describe TranslationsHelper do 14 | pending "add some examples to (or delete) #{__FILE__}" 15 | end 16 | -------------------------------------------------------------------------------- /salor-hospitality/db/migrate/20150709092033_create_item_types.rb: -------------------------------------------------------------------------------- 1 | class CreateItemTypes < ActiveRecord::Migration 2 | def change 3 | create_table :item_types do |t| 4 | t.string :name 5 | t.string :behavior 6 | t.integer :vendor_id 7 | t.integer :company_id 8 | t.boolean :hidden 9 | t.datetime :hidden_at 10 | t.integer :hidden_by 11 | 12 | t.timestamps 13 | end 14 | 15 | add_column :articles, :item_type_id, :integer 16 | add_column :items, :item_type_id, :integer 17 | end 18 | end 19 | -------------------------------------------------------------------------------- /salor-hospitality/app/assets/javascripts/hooks.js: -------------------------------------------------------------------------------- 1 | /* 2 | * Allows us to latch onto events in the UI for adding menu items, i.e. in this case, customers, but later more. 3 | */ 4 | function emit(msg,packet) { 5 | $('body').triggerHandler({type: msg, packet:packet}); 6 | } 7 | 8 | function connect(unique_name,msg,fun) { 9 | var pcd = _get('plugin_callbacks_done'); 10 | if (!pcd) 11 | pcd = []; 12 | if (pcd.indexOf(unique_name) == -1) { 13 | $('body').on(msg,fun); 14 | pcd.push(unique_name); 15 | } 16 | _set('plugin_callbacks_done',pcd) 17 | } -------------------------------------------------------------------------------- /salor-hospitality/config/initializers/wrap_parameters.rb: -------------------------------------------------------------------------------- 1 | # Be sure to restart your server when you modify this file. 2 | # 3 | # This file contains settings for ActionController::ParamsWrapper which 4 | # is enabled by default. 5 | 6 | # Enable parameter wrapping for JSON. You can disable this by setting :format to an empty array. 7 | ActiveSupport.on_load(:action_controller) do 8 | wrap_parameters format: [:json] 9 | end 10 | 11 | # Disable root element in JSON by default. 12 | ActiveSupport.on_load(:active_record) do 13 | self.include_root_in_json = false 14 | end 15 | -------------------------------------------------------------------------------- /salor-hospitality/app/views/statistics/_print_statistics_tax.txt.erb: -------------------------------------------------------------------------------- 1 | 2 | 3 | <%= "\e!\x38" %> 4 | <%= Tax.model_name.human %> 5 | 6 | <%= "\e!\x00" %> 7 | <% total = 0 %> 8 | <% @taxes.each do |tax| %> 9 | <% sum = @current_vendor.tax_items.existing.where(:refunded => nil, :user_id => @uids, :tax_id => tax, :cost_center_id => @csids, :settlement_id => @sids).sum(:gro) %> 10 | <%= "%10.10s %s %7.2f\n" % [tax.name, @friendly_unit, sum] %> 11 | <% total += sum %> 12 | <% end %> 13 | <%= "%10.10s %s %7.2f\n" % [I18n.t(:sum), @friendly_unit, total] %> 14 | <%= "\xc4" * 42 %> -------------------------------------------------------------------------------- /salor-hospitality/app/views/groups/index.html.haml: -------------------------------------------------------------------------------- 1 | %h2= t('activerecord.models.group.other') 2 | 3 | =link_to((t :new), new_group_path, :class => 'links') if @current_user.role >= 2 4 | 5 | %table 6 | %tr 7 | %th{ :style => 'width:200px' } 8 | %th{ :style => 'width:120px' } 9 | %th{ :style => 'width:120px' } 10 | - @groups.each do |gr| 11 | %tr 12 | %td= gr.name 13 | %td= link_to((t :edit), edit_group_path(gr)) if @current_user.role >= 2 14 | %td= link_to((t :delete), gr, :confirm => (t :are_you_sure), :method => :delete) if @current_user.role >= 3 15 | -------------------------------------------------------------------------------- /salor-hospitality/app/views/statistics/_print_statistics_category.txt.erb: -------------------------------------------------------------------------------- 1 | 2 | 3 | <%= "\e!\x38" %> 4 | <%= Category.model_name.human %> 5 | 6 | <%= "\e!\x00" %> 7 | <% total = 0 %> 8 | <% @categories.each do |cat| %> 9 | <% sum = @current_vendor.items.existing.where(:refunded => nil, :user_id => @uids, :category_id => cat, :cost_center_id => @csids, :settlement_id => @sids).sum(:sum) %> 10 | <%= "%10.10s %s %7.2f\n" % [cat.name, @friendly_unit, sum] %> 11 | <% total += sum %> 12 | <% end %> 13 | <%= "%10.10s %s %7.2f\n" % [I18n.t(:sum), @friendly_unit, total] %> 14 | <%= "\xc4" * 42 %> -------------------------------------------------------------------------------- /salor-hospitality/app/views/shared/_invoice_tax_list.html.haml: -------------------------------------------------------------------------------- 1 | %h4= t '.list_of_taxes' 2 | %table.taxes 3 | %tr 4 | %th.left= Tax.model_name.human 5 | %th.left= Tax.human_attribute_name(:percent) 6 | %th.right_wide= t(:net) 7 | %th.right_wide= t(:tax_amount) 8 | %th.right_wide= t(:gross) 9 | - model.taxes.each do |k,v| 10 | %tr 11 | %td.left== (#{v[:l]}) #{v[:e]} 12 | %td.left= number_to_percentage v[:p] 13 | %td.right_wide= number_to_currency v[:n] 14 | %td.right_wide= number_to_currency v[:t] 15 | %td.right_wide= number_to_currency v[:g] 16 | -------------------------------------------------------------------------------- /salor-hospitality/Gemfile: -------------------------------------------------------------------------------- 1 | source 'http://rubygems.org' 2 | 3 | ruby '2.1.5' 4 | 5 | gem 'rails', '4.1.8' 6 | gem 'rake', '10.3.2' 7 | gem 'rack', '1.5.2' 8 | gem 'kramdown', '1.4.2' 9 | gem 'jquery-rails', '3.1.2' 10 | gem 'jquery-ui-rails', '4.2.0' 11 | gem 'sass-rails', '4.0.3' 12 | gem 'sprockets', '2.11.0' 13 | gem 'uglifier', '2.5.3' 14 | gem 'serialport', '1.3.0' 15 | gem 'haml', '4.0.5' 16 | gem 'mysql2', '0.3.16' 17 | gem 'coffee-rails', '4.0.1' 18 | gem 'rmagick', '2.15.0' 19 | gem 'rubyzip', '0.9.9' 20 | gem 'therubyracer', '0.12.2' 21 | 22 | 23 | group :development do 24 | gem 'byebug' 25 | end -------------------------------------------------------------------------------- /salor-hospitality/config/database.yml.default: -------------------------------------------------------------------------------- 1 | development: 2 | adapter: mysql2 3 | encoding: utf8 4 | reconnect: false 5 | database: sh_development 6 | username: root 7 | password: root 8 | pool: 5 9 | host: localhost 10 | 11 | test: 12 | adapter: mysql2 13 | encoding: utf8 14 | reconnect: false 15 | database: sh_test 16 | username: root 17 | password: root 18 | pool: 5 19 | host: localhost 20 | 21 | production: 22 | adapter: mysql2 23 | encoding: utf8 24 | reconnect: false 25 | database: sh_production 26 | username: root 27 | password: root 28 | pool: 5 29 | host: localhost -------------------------------------------------------------------------------- /salor-hospitality/app/views/articles/_find.html.haml: -------------------------------------------------------------------------------- 1 | - @found_articles.each do |ar| 2 | %li.search_result{ :id => "searchresults_#{ ar.id }", :source => 'searchresults', :model_id => ar.id } 3 | = image_tag 'drag_handle.png', :id => "handle_for_article_#{ar.id}", :style => 'cursor:move;' 4 | = link_to ar.name, edit_article_path(ar) 5 | %br 6 | == (#{ar.quantities.existing.empty? ? number_to_currency(ar.price) : "#{ar.quantities.existing.size} #{t '.variants', :count => ar.quantities.existing.size }"}) 7 | %script== $('#searchresults_#{ ar.id }').draggable({ handle: 'handle_for_article_#{ ar.id }', revert: true }); 8 | -------------------------------------------------------------------------------- /salor-hospitality/app/views/statistics/_print_statistics_statistic_category.txt.erb: -------------------------------------------------------------------------------- 1 | 2 | 3 | <%= "\e!\x38" %> 4 | <%= StatisticCategory.model_name.human %> 5 | 6 | <%= "\e!\x00" %> 7 | <% total = 0 %> 8 | <% @statistic_categories.each do |cat| %> 9 | <% sum = @current_vendor.items.existing.where(:refunded => nil, :user_id => @uids, :statistic_category_id => cat, :cost_center_id => @csids, :settlement_id => @sids).sum(:sum) %> 10 | <%= "%10.10s %s %7.2f\n" % [cat.name, @friendly_unit, sum] %> 11 | <% total += sum %> 12 | <% end %> 13 | <%= "%10.10s %s %7.2f\n" % [I18n.t(:sum), @friendly_unit, total] %> 14 | <%= "\xc4" * 42 %> -------------------------------------------------------------------------------- /salor-hospitality/app/views/cameras/index.html.haml: -------------------------------------------------------------------------------- 1 | %h2= t('activerecord.models.camera.other') 2 | 3 | = link_to (t :new), new_camera_path, :class => 'links' 4 | 5 | .clear 6 | 7 | - @cameras.each do |c| 8 | %div.camera 9 | %p.delete= link_to image_tag('button_small_delete.png', :title => Camera.human_attribute_name(:hidden), :alt => Camera.human_attribute_name(:hidden)), camera_path(c), :method => :delete, :confirm => t(:are_you_sure) 10 | %h3= link_to c.name, edit_camera_path(c) 11 | %p= c.description 12 | %img.stream{ :src => c.resource(request.ip, 'snapshot') } 13 | %p= link_to t('.show'), camera_path(c) 14 | 15 | 16 | -------------------------------------------------------------------------------- /salor-hospitality/app/views/sessions/new_customer.html.haml: -------------------------------------------------------------------------------- 1 | #login 2 | - if mobile? 3 | = image_tag 'logo-small.png', :id => 'logo' 4 | = form_tag @submit_path do 5 | %p 6 | = label_tag 'email', Customer.human_attribute_name(:login) 7 | = text_field_tag 'email', '', :size => 9 8 | %br 9 | = label_tag 'password', (t '.password') 10 | = password_field_tag 'password', '', :size => 9 11 | = hidden_field_tag 'mode', 'customer' 12 | = hidden_field_tag 'v', params[:v] 13 | %p= submit_tag t('.login'), :class => 'submit' 14 | 15 | - if workstation? 16 | :javascript 17 | $('#password').focus(); 18 | -------------------------------------------------------------------------------- /salor-hospitality/app/views/statistics/_print_statistics_user.txt.erb: -------------------------------------------------------------------------------- 1 | 2 | 3 | <%= "\e!\x38" %> 4 | <%= User.model_name.human %> 5 | 6 | <%= "\e!\x00" %> 7 | <% total = 0 %> 8 | <% [@uids].flatten.each do |uid| %> 9 | <% next if uid.nil? %> 10 | <% sum = @current_vendor.items.existing.where(:refunded => nil, :user_id => uid, :cost_center_id => @csids, :settlement_id => @sids).sum(:sum) %> 11 | <% user = @current_vendor.users.find_by_id(uid) %> 12 | <%= "%10.10s %s %7.2f\n" % [user.login, @friendly_unit, sum] %> 13 | <% total += sum %> 14 | <% end %> 15 | <%= "%10.10s %s %7.2f\n" % [I18n.t(:sum), @friendly_unit, total] %> 16 | <%= "\xc4" * 42 %> -------------------------------------------------------------------------------- /salor-hospitality/app/views/room_types/index.html.haml: -------------------------------------------------------------------------------- 1 | %h2= t('activerecord.models.room_type.other') 2 | 3 | %p= link_to((t :new), new_room_type_path, :class => 'links') 4 | 5 | %table 6 | %tr 7 | %th{ :style => 'width:200px' }= RoomType.human_attribute_name(:name) 8 | %th{ :style => 'width:50px' } 9 | - @room_types.each do |t| 10 | %tr 11 | %td= link_to t.name, edit_room_type_path(t), :class => "list_item" 12 | %td= link_to image_tag('button_small_delete.png', :title => RoomType.human_attribute_name(:hidden), :alt => RoomType.human_attribute_name(:hidden)), room_type_path(t), :method => :delete, :confirm => t(:are_you_sure) 13 | -------------------------------------------------------------------------------- /salor-hospitality/app/views/payment_methods/index.html.haml: -------------------------------------------------------------------------------- 1 | %h2= t('activerecord.models.payment_method.other') 2 | 3 | = link_to (t :new), new_payment_method_path, :class => 'links' 4 | 5 | %table 6 | %tr 7 | %th{ :style => 'width:150px' } 8 | %th{ :style => 'width:50px' } 9 | - @payment_methods.each do |pm| 10 | %tr 11 | %td= link_to pm.name, edit_payment_method_path(pm), :class => "list_item" 12 | %td= link_to image_tag('button_small_delete.png', :title => PaymentMethod.human_attribute_name(:hidden), :alt => PaymentMethod.human_attribute_name(:hidden)), payment_method_path(pm), :method => :delete, :confirm => t(:are_you_sure) 13 | -------------------------------------------------------------------------------- /salor-hospitality/db/migrate/20150906175346_drop_model_numbers.rb: -------------------------------------------------------------------------------- 1 | class DropModelNumbers < ActiveRecord::Migration 2 | def up 3 | remove_column :vendors, :use_order_numbers 4 | remove_column :vendors, :use_booking_numbers 5 | remove_column :vendors, :use_settlement_numbers 6 | 7 | remove_column :vendors, :unused_order_numbers 8 | remove_column :vendors, :unused_booking_numbers 9 | remove_column :vendors, :unused_settlement_numbers 10 | 11 | remove_column :vendors, :largest_booking_number 12 | 13 | rename_column :vendors, :largest_order_number, :largest_invoice_number 14 | end 15 | 16 | def down 17 | end 18 | end -------------------------------------------------------------------------------- /salor-hospitality/app/views/articles/_scope_list.html.haml: -------------------------------------------------------------------------------- 1 | - @categories.each do |ca| 2 | - if @articleshash[scope][ca.id] and @articleshash[scope][ca.id].any? 3 | %p.category_title= ca.name 4 | %ul 5 | - @articleshash[scope][ca.id].each do |ar| 6 | %li{ :id => "#{ scope }_#{ ar.id }", :source => scope, :model_id => ar.id } 7 | = image_tag 'drag_handle.png', :id => "handle_for_#{ scope }_article_#{ ar.id }", :style => 'cursor:move' 8 | = link_to ar.name, edit_article_path(ar), :class => "list_item" 9 | %script== $('##{ scope }_#{ ar.id }').draggable({handle: '#handle_for_#{ scope }_article_#{ ar.id }', revert: true}); 10 | -------------------------------------------------------------------------------- /debian/rules: -------------------------------------------------------------------------------- 1 | #!/usr/bin/make -f 2 | # -*- makefile -*- 3 | # Sample debian/rules that uses debhelper. 4 | # This file was originally written by Joey Hess and Craig Small. 5 | # As a special exception, when this file is copied by dh-make into a 6 | # dh-make output file, you may use that output file without restriction. 7 | # This special exception was added by Craig Small in version 0.37 of dh-make. 8 | 9 | # Uncomment this to turn on verbose mode. 10 | #export DH_VERBOSE=1 11 | 12 | %: 13 | dh $@ 14 | 15 | override_dh_auto_clean: 16 | rm -rf salor-hospitality/log/*.log 17 | 18 | override_dh_install: 19 | dh_install --exclude=salor_saas --exclude=salor_cart --exclude=sh_saas 20 | -------------------------------------------------------------------------------- /salor-hospitality/app/views/statistic_categories/index.html.haml: -------------------------------------------------------------------------------- 1 | %h2= t('activerecord.models.statistic_category.other') 2 | 3 | = link_to (t :new), new_statistic_category_path, :class => 'links' 4 | 5 | %table 6 | %tr 7 | %th{ :style => 'width:150px' } 8 | %th{ :style => 'width:50px' } 9 | - @statistic_categories.each do |c| 10 | %tr 11 | %td= link_to c.name, edit_statistic_category_path(c), :class => "list_item" 12 | %td= link_to image_tag('button_small_delete.png', :title => StatisticCategory.human_attribute_name(:hidden), :alt => StatisticCategory.human_attribute_name(:hidden)), statistic_category_path(c), :method => :delete, :confirm => t(:are_you_sure) 13 | -------------------------------------------------------------------------------- /salor-hospitality/app/views/cost_centers/index.html.haml: -------------------------------------------------------------------------------- 1 | %h2= t('activerecord.models.cost_center.other') 2 | 3 | = link_to (t :new), new_cost_center_path, :class => 'links' 4 | 5 | %table 6 | %tr 7 | %th{ :style => 'width:150px' } 8 | %th{ :style => 'width:200px' } 9 | %th{ :style => 'width:50px' } 10 | - @cost_centers.each do |cc| 11 | %tr 12 | %td= link_to cc.name, edit_cost_center_path(cc), :class => "list_item" 13 | %td= cc.description 14 | %td= link_to image_tag('button_small_delete.png', :title => CostCenter.human_attribute_name(:hidden), :alt => CostCenter.human_attribute_name(:hidden)), cost_center_path(cc), :method => :delete, :confirm => t(:are_you_sure) 15 | -------------------------------------------------------------------------------- /salor-hospitality/app/views/statistics/_print_statistics_weekday.txt.erb: -------------------------------------------------------------------------------- 1 | 2 | 3 | <%= "\e!\x38" %> 4 | <%= I18n.t 'statistics.index.weekday' %> 5 | 6 | <%= "\e!\x00" %> 7 | <% i = 0 %> 8 | <% total = 0 %> 9 | <% @daynames.each do |day| %> 10 | <% sum = @current_vendor.orders.existing.where(:paid => true, :user_id => @uids, :cost_center_id => @csids, :settlement_id => @sids).where("WEEKDAY(DATE_ADD(finished_at, INTERVAL '#{ @current_vendor.total_utc_offset_hours }' HOUR)) = #{i}").sum(:sum) %> 11 | <%= "%10.10s %s %7.2f\n" % [day, @friendly_unit, sum] %> 12 | <% i += 1 %> 13 | <% total += sum %> 14 | <% end %> 15 | <%= "%10.10s %s %7.2f\n" % [I18n.t(:sum), @friendly_unit, total] %> 16 | <%= "\xc4" * 42 %> -------------------------------------------------------------------------------- /salor-hospitality/app/views/statistics/_statistics_table.html.haml: -------------------------------------------------------------------------------- 1 | %table.settlements.statistics 2 | %tr 3 | %th.bb= Table.model_name.human 4 | %th.bb= t :sum 5 | %th.bb.bar 6 | - sums = [] 7 | - i = 0 8 | - @tables.each do |table| 9 | - sums[i] = @current_vendor.orders.existing.where(:paid => true, :user_id => @uids, :table_id => table, :cost_center_id => @csids, :settlement_id => @sids).sum(:sum) 10 | - i += 1 11 | - maximum = sums.sort.last 12 | - i = 0 13 | - @tables.each do |table| 14 | %tr 15 | %td= table.name 16 | %td= number_to_currency sums[i] 17 | %td 18 | .statistics_bar{ :style => "width:#{2 + 200 * sums[i]/maximum}px" } 19 | - i += 1 -------------------------------------------------------------------------------- /salor-hospitality/app/views/rooms/index.html.haml: -------------------------------------------------------------------------------- 1 | %h2= t('activerecord.models.room.other') 2 | 3 | %p= link_to((t :new), new_room_path, :class => 'links') 4 | 5 | %table 6 | %tr 7 | %th{ :style => 'width:120px' }= Room.human_attribute_name(:name) 8 | %th{ :style => 'width:150px' }= Room.human_attribute_name(:class) 9 | %th{ :style => 'width:50px' } 10 | - @rooms.each do |r| 11 | %tr 12 | %td= link_to r.name, edit_room_path(r), :class => "list_item" 13 | %td= r.room_type.name 14 | %td= link_to image_tag('button_small_delete.png', :title => Room.human_attribute_name(:hidden), :alt => Room.human_attribute_name(:hidden)), room_path(r), :method => :delete, :confirm => t(:are_you_sure) 15 | -------------------------------------------------------------------------------- /debian/salor-hospitality.doc-base.EX: -------------------------------------------------------------------------------- 1 | Document: salor-hospitality 2 | Title: Debian salor-hospitality Manual 3 | Author: 4 | Abstract: This manual describes what salor-hospitality is 5 | and how it can be used to 6 | manage online manuals on Debian systems. 7 | Section: unknown 8 | 9 | Format: debiandoc-sgml 10 | Files: /usr/share/doc/salor-hospitality/salor-hospitality.sgml.gz 11 | 12 | Format: postscript 13 | Files: /usr/share/doc/salor-hospitality/salor-hospitality.ps.gz 14 | 15 | Format: text 16 | Files: /usr/share/doc/salor-hospitality/salor-hospitality.text.gz 17 | 18 | Format: HTML 19 | Index: /usr/share/doc/salor-hospitality/html/index.html 20 | Files: /usr/share/doc/salor-hospitality/html/*.html 21 | -------------------------------------------------------------------------------- /salor-hospitality/app/views/room_types/new.html.haml: -------------------------------------------------------------------------------- 1 | %h2= @room_type.new_record? ? (t '.new_room_type') : (t '.edit_room_type') 2 | 3 | - if @room_type.errors.any? 4 | .errors 5 | %h3= t 'activerecord.errors.template.header', :count => @room_type.errors.size, :model => RoomType.model_name.human 6 | %ul 7 | - @room_type.errors.full_messages.each do |msg| 8 | %li= msg 9 | 10 | .form_fields 11 | = form_for @room_type do |room_type_form| 12 | = submit_tag( controller.action_name == 'new' ? (t :create) : (t :edit) ) 13 | .floatright= link_to(t('various.cancel'), room_types_path, :class => 'links') 14 | .clear 15 | = room_type_form.label :name 16 | = room_type_form.text_field :name, :size => '20' 17 | -------------------------------------------------------------------------------- /salor-hospitality/app/views/plugins/index.html.haml: -------------------------------------------------------------------------------- 1 | %h2= t('activerecord.models.plugin.other') 2 | 3 | %p= link_to((t :new), new_plugin_path, :class => 'links') 4 | 5 | %table 6 | %tr 7 | %th{ :style => 'width:120px' }= Plugin.human_attribute_name(:name) 8 | %th{ :style => 'width:50px' } 9 | %th{ :style => 'width:50px' } 10 | - @plugins.each do |p| 11 | %tr 12 | %td= link_to p.name, edit_plugin_path(p), :class => "list_item" 13 | %td 14 | %img{ :style => "width: 50px", :src => p.icon } 15 | %td= link_to image_tag('button_small_delete.png', :title => Plugin.human_attribute_name(:hidden), :alt => Plugin.human_attribute_name(:hidden)), plugin_path(p), :method => :delete, :confirm => t(:are_you_sure) 16 | -------------------------------------------------------------------------------- /salor-hospitality/app/views/settlements/edit.html.haml: -------------------------------------------------------------------------------- 1 | %h2= t :settlement 2 | 3 | - if @settlement.errors.any? 4 | .errors 5 | %h3= t 'activerecord.errors.template.header', :count => @settlement.errors.size, :model => Settlement.model_name.human 6 | %ul 7 | - @settlement.errors.full_messages.each do |msg| 8 | %li= msg 9 | 10 | = render :partial => 'detailed_list', :locals => { :orders => @settlement.orders, :selected_cost_center => @cost_center } 11 | 12 | - path = user_settlement_path(@settlement.user, @settlement) 13 | - form_for :settlement, @settlement, :url => path, :html => { :method => 'put' } do |sm_form| 14 | = sm_form.label('created_at', 'Datum') 15 | = sm_form.date_select('created_at') 16 | = submit_tag 17 | -------------------------------------------------------------------------------- /salor-hospitality/config/initializers/escper.rb: -------------------------------------------------------------------------------- 1 | Escper.setup do |config| 2 | if SalorHospitality::Application::SH_DEBIAN_SITEID != 'none' 3 | config.codepage_file = File.join('/', 'etc', 'salor-hospitality', SalorHospitality::Application::SH_DEBIAN_SITEID, 'codepages.yml') 4 | else 5 | config.codepage_file = File.join(Rails.root, 'config', 'codepages.yml') 6 | end 7 | 8 | config.use_safe_device_path = SalorHospitality::Application::CONFIGURATION[:use_safe_device_path] == true ? true : false 9 | 10 | if SalorHospitality::Application::SH_DEBIAN_SITEID != 'none' 11 | config.safe_device_path = File.join('/', 'var', 'lib', 'salor-hospitality', SalorHospitality::Application::SH_DEBIAN_SITEID, 'public', 'uploads') 12 | end 13 | end -------------------------------------------------------------------------------- /salor-hospitality/app/assets/javascripts/dates.js: -------------------------------------------------------------------------------- 1 | function date_as_ymd(date) { 2 | var ret = date.getFullYear() + '-' + (date.getMonth()+1) + '-' + date.getDate(); 3 | return ret; 4 | } 5 | 6 | function date_as_md(date) { 7 | var ret = ( date.getMonth() + 1) + '-' + date.getDate(); 8 | return ret; 9 | } 10 | 11 | function get_date(str) { 12 | // This for some reason was not working, 13 | // so I rewrote it...hope it doesn't break anything 14 | var parts = str.split('-'); 15 | var d = new Date(parts[0],parseInt(parts[1]) - 1,parts[2]); 16 | return d; 17 | } 18 | 19 | function days_between_dates(from, to) { 20 | var days = Math.floor((Date.parse(to) - Date.parse(from)) / 86400000); 21 | if (days == 0) 22 | days = 0 23 | return days; 24 | } -------------------------------------------------------------------------------- /salor-hospitality/app/views/exception_notifier/background_exception_notification.text.erb: -------------------------------------------------------------------------------- 1 | <%= @exception.class.to_s =~ /^[aeiou]/i ? 'An' : 'A' %> <%= @exception.class %> occurred in background at <%= raw Time.current %> : 2 | 3 | <%= @exception.message %> 4 | <%= @backtrace.first %> 5 | 6 | <% sections = @sections.map do |section| 7 | summary = render(section).strip 8 | unless summary.blank? 9 | title = render("title", :title => section).strip 10 | "#{title}\n\n#{summary.gsub(/^/, " ")}\n\n" 11 | end 12 | end.join 13 | sections = sections.force_encoding('UTF-8').encode('UTF-16', :invalid => :replace).encode('UTF-8') if sections.respond_to?(:force_encoding) 14 | %> 15 | <%= raw sections %> 16 | -------------------------------------------------------------------------------- /salor-hospitality/app/views/room_prices/new.html.haml: -------------------------------------------------------------------------------- 1 | %h2= @room_price.new_record? ? (t '.new_room_price') : (t '.edit_room_price') 2 | 3 | - if @room_price.errors.any? 4 | .errors 5 | %h3= t 'activerecord.errors.template.header', :count => @room_price.errors.size, :model => RoomPrice.model_name.human 6 | %ul 7 | - @room_price.errors.full_messages.each do |msg| 8 | %li= msg 9 | 10 | .form_fields 11 | = form_for @room_price do |room_price_form| 12 | = submit_tag( controller.action_name == 'new' ? (t :create) : (t :edit) ) 13 | .floatright= link_to(t('various.cancel'), room_prices_path, :class => 'links') 14 | .clear 15 | = room_price_form.label :base_price 16 | = room_price_form.text_field :base_price, :size => 5 17 | -------------------------------------------------------------------------------- /salor-hospitality/app/views/statistics/_statistics_statistic_category.html.haml: -------------------------------------------------------------------------------- 1 | %table.settlements.statistics 2 | %tr 3 | %th.bb= StatisticCategory.model_name.human 4 | %th.bb= t :sum 5 | %th.bb.bar 6 | - sums = [] 7 | - i = 0 8 | - @statistic_categories.each do |cat| 9 | - sums[i] = @current_vendor.items.existing.where(:refunded => nil, :user_id => @uids, :statistic_category_id => cat, :cost_center_id => @csids, :settlement_id => @sids).sum(:sum) 10 | - i += 1 11 | - maximum = sums.sort.last 12 | - i = 0 13 | - @statistic_categories.each do |cat| 14 | %tr 15 | %td= cat.name 16 | %td= number_to_currency sums[i] 17 | %td 18 | .statistics_bar{ :style => "width:#{2 + 200 * sums[i]/maximum}px" } 19 | - i += 1 -------------------------------------------------------------------------------- /salor-hospitality/app/assets/javascripts/jquery-data.js: -------------------------------------------------------------------------------- 1 | function _get(name,context) { 2 | if (context) { 3 | // if you pass in a 3rd argument, which should be an html element, then that is set as teh context. 4 | // this ensures garbage collection of the values when that element is removed. 5 | return $.data(context[0],name); 6 | } else { 7 | return $.data(document.body,name); 8 | } 9 | } 10 | function _set(name,value,context) { 11 | if (context) { 12 | // if you pass in a 3rd argument, which should be an html element, then that is set as teh context. 13 | // this ensures garbage collection of the values when that element is removed. 14 | return $.data(context[0],name,value); 15 | } else { 16 | return $.data(document.body,name,value); 17 | } 18 | } -------------------------------------------------------------------------------- /salor-hospitality/app/assets/javascripts/scrolling.js: -------------------------------------------------------------------------------- 1 | function scroll_to(element, speed) { 2 | target_y = $(window).scrollTop(); 3 | //current_y = $(element).offset().top; 4 | var elementid = $(element).attr('id'); 5 | current_y = document.getElementById(elementid).offsetTop; 6 | if (settings.workstation) { 7 | do_scroll((current_y - target_y)*1.05, speed); 8 | } else { 9 | window.scrollTo(0, current_y); 10 | } 11 | } 12 | 13 | function scroll_for(distance, speed) { 14 | do_scroll(distance, speed); 15 | } 16 | 17 | function do_scroll(diff, speed) { 18 | window.scrollBy(0,diff/speed); 19 | newdiff = (speed-1)*diff/speed; 20 | scrollAnimation = setTimeout(function(){ do_scroll(newdiff, speed) }, 20); 21 | if(Math.abs(diff) < 5) { clearTimeout(scrollAnimation); } 22 | } -------------------------------------------------------------------------------- /salor-hospitality/app/views/orders/_areas.html.haml: -------------------------------------------------------------------------------- 1 | - areas = 4 2 | - 1.upto(areas) do |area| 3 | %div.area{ :id => "area#{ area }" } 4 | - if permit('mobile_show_tools') 5 | %a.mobile_last_invoices_button.iconbutton.previous_button 6 | - 1.upto(areas) do |icon| 7 | - style = icon == area ? "border: 2px solid #{ @current_user.color };" : '' 8 | %a{ :class => "iconbutton area#{icon}_button", :style => style, :onclick => "scroll_to('#area#{ icon }',10)", :title => "#{t(:scroll_to_area)} #{ icon }" } 9 | %a.iconbutton.logout_button{ :onclick => "logout()" } 10 | 11 | :javascript 12 | $('.mobile_last_invoices_button').on('mousedown', function() { 13 | $.ajax({ 14 | type: 'GET', 15 | cache: false, 16 | url: '/orders/last_invoices' 17 | }); 18 | }) -------------------------------------------------------------------------------- /salor-hospitality/app/views/layouts/iframe.html.haml: -------------------------------------------------------------------------------- 1 | !!! 2 | 3 | %html 4 | %head 5 | %meta{ 'http-equiv' => 'Content-Type', :content => 'text/html; charset=utf-8' } 6 | - if mobile? 7 | %meta{ 'name' => "viewport", :content => "width=device-width; initial-scale=1.0; maximum-scale=1.0; user-scalable=0;" } 8 | %meta{ 'name' => "apple-mobile-web-app-capable", :content => "yes" } 9 | 10 | %title BillGastro 11 | 12 | = javascript_include_tag 'jquery.js' 13 | = javascript_include_tag 'page.js' 14 | = javascript_include_tag 'menucard_iframe.js' 15 | 16 | %style= render :file => 'app/views/layouts/_fonts.css.erb', :content_type => 'text/css' 17 | 18 | = stylesheet_link_tag('iframe', :media => 'screen') 19 | 20 | %body 21 | #digital_menucard= yield 22 | -------------------------------------------------------------------------------- /salor-hospitality/app/views/guest_types/index.html.haml: -------------------------------------------------------------------------------- 1 | %h2= t('activerecord.models.guest_type.other') 2 | 3 | %p= link_to((t :new), new_guest_type_path, :class => 'links') 4 | 5 | %table 6 | %tr 7 | %th{ :style => 'width:180px' }= GuestType.human_attribute_name(:name) 8 | %th{ :style => 'width:220px' }= GuestType.human_attribute_name(:taxes) 9 | %th{ :style => 'width:50px' } 10 | - @guest_types.each do |g| 11 | %tr 12 | %td= link_to g.name, edit_guest_type_path(g), :class => "list_item" 13 | %td= g.taxes.collect{ |tax| "#{tax.name} (#{tax.percent}%)" }.join(', ') 14 | %td= link_to image_tag('button_small_delete.png', :title => GuestType.human_attribute_name(:hidden), :alt => GuestType.human_attribute_name(:hidden)), guest_type_path(g), :method => :delete, :confirm => t(:are_you_sure) 15 | -------------------------------------------------------------------------------- /salor-hospitality/app/views/rooms/new.html.haml: -------------------------------------------------------------------------------- 1 | %h2= @room.new_record? ? (t '.new_room') : (t '.edit_room') 2 | 3 | - if @room.errors.any? 4 | .errors 5 | %h3= t 'activerecord.errors.template.header', :count => @room.errors.size, :model => Room.model_name.human 6 | %ul 7 | - @room.errors.full_messages.each do |msg| 8 | %li= msg 9 | 10 | .form_fields 11 | = form_for @room do |room_form| 12 | = submit_tag( controller.action_name == 'new' ? (t :create) : (t :edit) ) 13 | .floatright= link_to(t('various.cancel'), rooms_path, :class => 'links') 14 | .clear 15 | = room_form.label :name 16 | = room_form.text_field :name, :size => '20' 17 | %br 18 | = room_form.label :room_type_id 19 | = room_form.select :room_type_id, @room_types.collect{|r| [r.name,r.id]}, :include_blank => true 20 | -------------------------------------------------------------------------------- /salor-hospitality/app/views/statistics/_statistics_category.html.haml: -------------------------------------------------------------------------------- 1 | %table.settlements.statistics 2 | %tr 3 | %th.bb= Category.model_name.human 4 | %th.bb= t :sum 5 | %th.bb.bar 6 | - sums = [] 7 | - i = 0 8 | - @categories.each do |cat| 9 | - sums[i] = @current_vendor.items.existing.where(:refunded => nil, :user_id => @uids, :category_id => cat.id, :cost_center_id => @csids, :settlement_id => @sids).sum(:sum) 10 | - i += 1 11 | - maximum = sums.sort.last 12 | - i = 0 13 | - @categories.each do |cat| 14 | %tr 15 | %td= cat.name 16 | %td= number_to_currency sums[i] 17 | %td 18 | .statistics_bar{ :style => "width:#{2 + 200 * sums[i]/maximum}px" } 19 | - i += 1 20 | %tfoot 21 | %tr 22 | %td 23 | %td 24 | %b= number_to_currency sums.sum 25 | %td -------------------------------------------------------------------------------- /salor-hospitality/app/views/statistics/_statistics_tax.html.haml: -------------------------------------------------------------------------------- 1 | %table.settlements.statistics 2 | %tr 3 | %th.bb= Tax.model_name.human 4 | %th.bb= t :sum 5 | %th.bb.bar 6 | - sums = [] 7 | - total = 0 8 | - i = 0 9 | - @taxes.each do |tax| 10 | - sums[i] = @current_vendor.tax_items.existing.where(:refunded => nil, :user_id => @uids, :tax_id => tax, :cost_center_id => @csids, :settlement_id => @sids).sum(:gro) 11 | - total += sums[i] 12 | - i += 1 13 | 14 | - maximum = sums.sort.last 15 | - i = 0 16 | - @taxes.each do |tax| 17 | %tr 18 | %td= tax.name 19 | %td= number_to_currency sums[i] 20 | %td 21 | .statistics_bar{ :style => "width:#{2 + 200 * sums[i]/maximum}px" } 22 | - i += 1 23 | %tr 24 | %td= t(:sum) 25 | %td= number_to_currency total 26 | %td -------------------------------------------------------------------------------- /salor-hospitality/config/codepages.yml: -------------------------------------------------------------------------------- 1 | --- 2 | # Codepage 0 corresponds to the codepage 0 of Metapace T family of thermal printers 3 | 0: 4 | ä: 0x84 5 | ü: 0x81 6 | ö: 0x94 7 | Ä: 0x8E 8 | Ü: 0x9A 9 | Ö: 0x99 10 | é: 0x82 11 | è: 0x8A 12 | ú: 0xA3 13 | ù: 0x97 14 | á: 0xA0 15 | à: 0x85 16 | í: 0xA1 17 | ì: 0x8D 18 | ó: 0xA2 19 | ò: 0x95 20 | â: 0x83 21 | ê: 0x88 22 | î: 0x8C 23 | ô: 0x93 24 | û: 0x96 25 | ñ: 0xA4 26 | ß: 0xE1 27 | —: 0xDF 28 | 1: 29 | ä: 0x84 30 | ü: 0x81 31 | ö: 0x94 32 | Ä: 0x8E 33 | Ü: 0x9A 34 | Ö: 0x99 35 | é: 0x82 36 | è: 0x8A 37 | ú: 0xA3 38 | ù: 0x97 39 | á: 0xA0 40 | à: 0x85 41 | í: 0xA1 42 | ì: 0x8D 43 | ó: 0xA2 44 | ò: 0x95 45 | â: 0x83 46 | ê: 0x88 47 | î: 0x8C 48 | ô: 0x93 49 | û: 0x96 50 | ñ: 0xA4 51 | ß: 0xE1 52 | —: 0x2D -------------------------------------------------------------------------------- /salor-hospitality/app/models/user_login.rb: -------------------------------------------------------------------------------- 1 | class UserLogin < ActiveRecord::Base 2 | include Scope 3 | include Base 4 | 5 | belongs_to :company 6 | belongs_to :vendor 7 | belongs_to :user 8 | 9 | before_save :set_duration 10 | 11 | def set_duration 12 | if self.login.nil? 13 | # this is a logout item 14 | last_login = self.user.user_logins.where(:logout => nil).last 15 | return 0 if last_login.nil? 16 | self.duration = (self.logout - last_login.login).to_i / 60 # duration is in minutes 17 | return self.duration 18 | end 19 | end 20 | 21 | def self.duration_formatted(seconds) 22 | duration_hours = seconds / 60.0 23 | hours = Integer(duration_hours) 24 | minutes = (duration_hours - hours) * 60 25 | return "#{ hours }:#{ "%02i" % minutes }" 26 | end 27 | 28 | end 29 | -------------------------------------------------------------------------------- /salor-hospitality/app/views/vendors/index.html.haml: -------------------------------------------------------------------------------- 1 | %h2= t('activerecord.models.vendor.other') 2 | 3 | %table 4 | %tr 5 | %th{ :width => '250px' } 6 | %th{ :width => '150px' } 7 | %th{ :width => '50px' } 8 | - @vendors.each do |v| 9 | %tr 10 | %td= link_to v.name, edit_vendor_path(v), :class => "list_item" 11 | %td= link_to "", vendor_path(v), :title => t('.switch_to'), :class => "iconbutton exit_button" 12 | - if @current_vendor != v and @current_company.users.existing.where(:default_vendor_id => v.id).empty? and v.users.existing == [@current_user] 13 | %td= link_to image_tag('button_small_delete.png', :title => Vendor.human_attribute_name(:hidden), :alt => Vendor.human_attribute_name(:hidden)), vendor_path(v), :method => :delete, :confirm => t(:are_you_sure) if @current_company.vendors.existing.count > 1 14 | -------------------------------------------------------------------------------- /salor-hospitality/public/422.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | The change you wanted was rejected (422) 5 | 17 | 18 | 19 | 20 | 21 |
22 |

The change you wanted was rejected.

23 |

Maybe you tried to change something you didn't have access to.

24 |
25 | 26 | 27 | -------------------------------------------------------------------------------- /salor-hospitality/app/views/presentations/index.html.haml: -------------------------------------------------------------------------------- 1 | %h2= t('activerecord.models.presentation.other') 2 | 3 | %p= link_to((t :new), new_presentation_path, :class => 'links') 4 | 5 | %table 6 | %tr 7 | %th{ :style => 'width:250px' }= Presentation.human_attribute_name(:name) 8 | %th{ :style => 'width:100px' }= Presentation.human_attribute_name(:model) 9 | %th{ :style => 'width:200px' }= Presentation.human_attribute_name(:description) 10 | - @presentations.each do |p| 11 | %tr 12 | %td= link_to p.name, edit_presentation_path(p), :class => "list_item" 13 | %td= p.model 14 | %td= p.description 15 | %td= link_to image_tag('button_small_delete.png', :title => Presentation.human_attribute_name(:hidden), :alt => Presentation.human_attribute_name(:hidden)), presentation_path(p), :method => :delete, :confirm => t(:are_you_sure) 16 | -------------------------------------------------------------------------------- /salor-hospitality/public/404.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | The page you were looking for doesn't exist (404) 5 | 17 | 18 | 19 | 20 | 21 |
22 |

The page you were looking for doesn't exist.

23 |

You may have mistyped the address or the page may have moved.

24 |
25 | 26 | 27 | -------------------------------------------------------------------------------- /salor-hospitality/public/500.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | We're sorry, but something went wrong (500) 5 | 17 | 18 | 19 | 20 | 21 |
22 |

We're sorry, but something went wrong.

23 |

We've been notified about this issue and we'll take a look at it shortly.

24 |
25 | 26 | 27 | -------------------------------------------------------------------------------- /salor-hospitality/app/views/surcharges/_tax_amount.html.haml: -------------------------------------------------------------------------------- 1 | - id = /surcharge\[tax_amounts_attributes\]\[(.*)\]/.match(f.object_name)[1] 2 | %div{ :id => "tax_amount_#{ id }" } 3 | = f.label :amount, t('activerecord.attributes.tax_amount.amount'), :class => 'medium' 4 | = f.text_field :amount, :size => 9 5 | %br 6 | = f.label :tax_id, t('activerecord.attributes.tax_amount.tax_id'), :class => 'medium' 7 | = f.select :tax_id, @taxes.collect{ |t| [ t.custom_name, t.id ] }, :include_blank => true 8 | %br 9 | - unless f.object.new_record? 10 | %span.link{ :onclick => "$('#surcharge_tax_amounts_attributes_#{ id }_hidden').val(1); $('#tax_amount_#{ id }').hide();" }= image_tag('button_small_delete.png', :title => TaxAmount.human_attribute_name(:hidden), :alt => TaxAmount.human_attribute_name(:hidden)) 11 | 12 | = f.hidden_field :hidden 13 | %br 14 | %br 15 | -------------------------------------------------------------------------------- /salor-hospitality/app/views/orders/last_invoices.js.erb: -------------------------------------------------------------------------------- 1 | counter_update_tables = -1; 2 | counter_update_item_lists = 2; 3 | 4 | $('#invoices').html(''); 5 | 6 | <% @permitted_users.each do |u| %> 7 | $('#invoices').append("<%= escape_javascript render(:partial => 'settlements/settlement', :locals => { :u => u } ) %>"); 8 | <% end %> 9 | 10 | $('#invoices').append('<%= escape_javascript render(:partial => 'order_summary', :collection => @recent_unsettled_orders) %>'); 11 | 12 | $('#orderform').hide(); 13 | $('#tables').hide(); 14 | $('#areas').hide(); 15 | $('#rooms').hide(); 16 | $('#functions_header_order_form').hide(); 17 | $('#functions_footer').hide(); 18 | $('#functions_header_index').hide(); 19 | //$('#functions_header_index').hide(); 20 | 21 | $('#invoices').show(); 22 | $('#items_notifications_interactive').show(); 23 | $('#functions_header_last_invoices').show(); 24 | 25 | -------------------------------------------------------------------------------- /salor-hospitality/app/views/statistics/_statistics_user.html.haml: -------------------------------------------------------------------------------- 1 | %table.settlements.statistics 2 | %tr 3 | %th.bb= User.model_name.human 4 | %th.bb= t :sum 5 | %th.bb.bar 6 | - sums = [] 7 | - i = 0 8 | - [@uids].flatten.each do |uid| 9 | - sums[i] = @current_vendor.items.existing.where(:refunded => nil, :user_id => uid, :cost_center_id => @csids, :settlement_id => @sids).sum(:sum) 10 | - i += 1 11 | - maximum = sums.sort.last 12 | - i = 0 13 | - [@uids].flatten.each do |uid| 14 | - next if uid.nil? 15 | - user = @current_vendor.users.find_by_id(uid) 16 | %tr 17 | %td= user.login 18 | %td= number_to_currency sums[i] 19 | %td 20 | .statistics_bar{ :style => "width:#{2 + 200 * sums[i]/maximum}px" } 21 | - i += 1 22 | %tr 23 | %td 24 | %b= t :sum 25 | %td 26 | %b= number_to_currency sums.sum 27 | %td -------------------------------------------------------------------------------- /salor-hospitality/app/views/seasons/index.html.haml: -------------------------------------------------------------------------------- 1 | %h2= t('activerecord.models.season.other') 2 | 3 | %p= link_to((t :new), new_season_path, :class => 'links') 4 | 5 | %table 6 | %tr 7 | %th{ :style => 'width:180px' }= Season.human_attribute_name(:name) 8 | %th{ :style => 'width:120px' }= Season.human_attribute_name(:from_date) 9 | %th{ :style => 'width:120px' }= Season.human_attribute_name(:to_date) 10 | %th{ :style => 'width:50px' } 11 | - @seasons.each do |g| 12 | %tr 13 | %td= link_to g.name, edit_season_path(g), :class => "list_item" 14 | %td= l g.from_date, :format => :month_and_day 15 | %td= l g.to_date, :format => :month_and_day 16 | %td= link_to image_tag('button_small_delete.png', :title => Season.human_attribute_name(:hidden), :alt => GuestType.human_attribute_name(:hidden)), season_path(g), :method => :delete, :confirm => t(:are_you_sure) 17 | -------------------------------------------------------------------------------- /salor-hospitality/app/views/statistic_categories/new.html.haml: -------------------------------------------------------------------------------- 1 | %h2= @statistic_category.new_record? ? (t '.new_statistic_category') : (t '.edit_statistic_category') 2 | 3 | - if @statistic_category.errors.any? 4 | .errors 5 | %h3= t 'activerecord.errors.template.header', :count => @statistic_category.errors.size, :model => StatisticCategory.model_name.human 6 | %ul 7 | - @statistic_category.errors.full_messages.each do |msg| 8 | %li= msg 9 | 10 | .form_fields 11 | = form_for @statistic_category do |statistic_category_form| 12 | = submit_tag( controller.action_name == 'new' ? (t :create) : (t :edit) ) 13 | .floatright= link_to(t('various.cancel'), statistic_categories_path, :class => 'links') 14 | .clear 15 | %table 16 | %tr 17 | %td= statistic_category_form.label 'name' 18 | %td= statistic_category_form.text_field :name, :size => '10' 19 | -------------------------------------------------------------------------------- /salor-hospitality/app/views/users/show.html.haml: -------------------------------------------------------------------------------- 1 | %h2= @user.login 2 | 3 | %a.iconbutton.back_button{ :href => '/users', :title => t(:go_back) } 4 | 5 | %br 6 | %br 7 | 8 | %h3= t("activerecord.models.user_login.other") 9 | 10 | = form_tag user_path(@user), :method => :get, :id => 'statisticform' do 11 | .limitby 12 | = label 'from', t('settlements.index.start_date'), :class => 'right' 13 | = select_date(@from, :prefix => 'from', :order => [:year, :month, :day]) 14 | %br 15 | = label 'to', t('settlements.index.end_date'), :class => 'right' 16 | = select_date(@to, :prefix => 'to', :order => [:year, :month, :day]) 17 | %br 18 | %span.button{ :onclick => "$('form#statisticform').submit()"}= t('various.display') 19 | 20 | .clear 21 | = render :partial => "logins_table", :locals => { :user_logins => @user_logins, :user => @user, :last_login => @user.user_logins.last } 22 | -------------------------------------------------------------------------------- /salor-hospitality/app/views/customers/index.html.haml: -------------------------------------------------------------------------------- 1 | %h2= t('activerecord.models.customer.other') 2 | 3 | = link_to (t :new), new_customer_path, :class => 'links' 4 | = link_to 'CSV', '/customers.csv', :class => 'links' 5 | 6 | %table 7 | %tr 8 | %th{ :style => 'width:300px' }= Customer.human_attribute_name :full_name 9 | %th{ :style => 'width:200px' }= Customer.human_attribute_name :city 10 | - @current_company.vendors.existing.each do |v| 11 | %tr 12 | %td{ :colspan => 3 } 13 | %h3= v.name 14 | - v.customers.existing.reverse.each do |c| 15 | %tr 16 | %td= link_to c.full_name, edit_customer_path(c), :class => "list_item" 17 | %td= c.city 18 | %td= link_to image_tag('button_small_delete.png', :title => Customer.human_attribute_name(:hidden), :alt => Customer.human_attribute_name(:hidden)), customer_path(c), :method => :delete, :confirm => t(:are_you_sure) 19 | -------------------------------------------------------------------------------- /salor-hospitality/app/views/taxes/index.html.haml: -------------------------------------------------------------------------------- 1 | %h2= t('activerecord.models.tax.other') 2 | 3 | %p= link_to((t :new), new_tax_path, :class => 'links') 4 | 5 | %table 6 | %tr 7 | %th{ :style => 'width:120px' }= Tax.human_attribute_name(:name) 8 | %th{ :style => 'width:100px' }= Tax.human_attribute_name(:percent) 9 | %th{ :style => 'width:100px' }= Tax.human_attribute_name(:letter) 10 | %th{ :style => 'width:100px' }= Tax.human_attribute_name(:tpe) 11 | %th{ :style => 'width:50px' } 12 | - @taxes.each do |ta| 13 | %tr 14 | %td= link_to ta.name, edit_tax_path(ta), :class => "list_item" 15 | %td= number_to_percentage ta.percent 16 | %td= ta.letter 17 | %td= ta.tpe 18 | %td= link_to image_tag('button_small_delete.png', :title => Tax.human_attribute_name(:hidden), :alt => Tax.human_attribute_name(:hidden)), tax_path(ta), :method => :delete, :confirm => t(:are_you_sure) 19 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | *.*~ 2 | *.swo 3 | #.* 4 | #*# 5 | 6 | *.# 7 | *.sql 8 | *.css 9 | *.swp 10 | *.escpos 11 | *.xcf 12 | *~ 13 | *.deb 14 | tmp 15 | salor-hospitality/tmp/*.txt 16 | salor-hospitality/tmp/sass-cache 17 | salor-hospitality/tmp/pids 18 | salor-hospitality/tmp/cache 19 | salor-hospitality/tmp/capybara 20 | salor-hospitality/tmp/sockets 21 | salor-hospitality/public/uploads/* 22 | salor-hospitality/vendor/bundle 23 | salor-hospitality/vendor/plugins 24 | salor-hospitality/vendor/cache 25 | salor-hospitality/.bundle 26 | salor-hospitality/config/database.yml 27 | *.log 28 | *.bill 29 | .sass-cache 30 | *.swn 31 | *.swm 32 | *.kate-swp 33 | sha1-signatures.txt 34 | *.tar.bz2 35 | debian/salor-hospitality 36 | debian/files 37 | *.debhelper 38 | *.substvars 39 | *.sh_saas.rb 40 | *.salor_cart.rb 41 | *.salor_saas.rb 42 | bar 43 | *.salor 44 | log/*.yml 45 | salor-hospitality/.DS_Store 46 | salor-hospitality/config/.DS_Store 47 | .DS_Store 48 | -------------------------------------------------------------------------------- /salor-hospitality/app/views/settlements/detailed_list.html.haml: -------------------------------------------------------------------------------- 1 | - if @settlement.id 2 | %h2== #{ t('activerecord.models.settlement.one') } ##{ @settlement.nr } #{ @settlement.user.login if @settlement.user } 3 | - else 4 | %h2== #{ t('activerecord.models.settlement.one') } #{ @settlement.user.login if @settlement.user } 5 | 6 | - if @settlement.id 7 | = link_to '', "/settlements/print/#{ @settlement.id }", :class => 'iconbutton print2_button', :remote => true 8 | %p= text_field_tag 'date' 9 | 10 | = render :partial => 'detailed_list', :locals => { :orders => @orders } 11 | 12 | - if @settlement.id 13 | :javascript 14 | $('#date').datepicker({ 15 | onSelect: function(date, inst) { 16 | $(this).val('OK'); 17 | $.ajax({ 18 | url: '/route', 19 | data: {currentview:'push',relation:'settlements',id:#{@settlement.id},model:{created_at:date + ' 00:00:00'}} 20 | }) 21 | } 22 | }) -------------------------------------------------------------------------------- /salor-hospitality/app/assets/javascripts/orders-documentready.js: -------------------------------------------------------------------------------- 1 | $(function(){ 2 | update_resources('documentready'); 3 | 4 | if (typeof(manage_counters_interval) == 'undefined') { 5 | manage_counters_interval = window.setInterval("manage_counters();", 1000); 6 | } 7 | 8 | if (!_get('customers.button_added')) { 9 | connect('customers_entry_hook','after.go_to.table',add_customers_button); 10 | } 11 | 12 | if (!_get('dmenucard.button_added')) { 13 | connect('dmenucard_entry_hook','after.go_to.table',add_dmenucard_button); 14 | } 15 | 16 | if (settings.workstation) { 17 | $("#sku_input").on("keypress", function(e) { 18 | if(e.which == 13) { 19 | add_item_by_sku($(this).val()); 20 | $("#sku_input").val(""); 21 | $("#sku_input").focus(); 22 | } 23 | }); 24 | 25 | $("#sku_input").on("click", function() { 26 | $("#sku_input").select(); 27 | }); 28 | } 29 | }) -------------------------------------------------------------------------------- /salor-hospitality/app/views/room_prices/index.html.haml: -------------------------------------------------------------------------------- 1 | %h2= t('activerecord.models.room_price.other') 2 | 3 | %p= link_to((t '.generate_price_skeleton'), 'room_prices/generate', :class => 'links') 4 | 5 | - @seasons.each do |s| 6 | %table.settlements.hotel 7 | %tr 8 | %th{ :style => 'width:100px' } 9 | %b= s.name 10 | - @room_types.each do |rt| 11 | %th{ :style => 'width:70px' }= rt.name 12 | - @guest_types.each do |gt| 13 | %tr 14 | %td= gt.name.upcase 15 | - @room_types.each do |rt| 16 | - room_price_object = @current_vendor.room_prices.existing.where(:season_id => s.id, :room_type_id => rt.id, :guest_type_id => gt.id).first 17 | - next if room_price_object.nil? 18 | - base_price = room_price_object.base_price 19 | %td{:class => "#{'highlighted' if base_price.zero?}" }= link_to number_to_currency(base_price), edit_room_price_path(room_price_object) 20 | -------------------------------------------------------------------------------- /salor-hospitality/app/views/pages/show.html.haml: -------------------------------------------------------------------------------- 1 | - if @current_user 2 | %h2= t('activerecord.models.page.other') 3 | 4 | = link_to (t '.slideshow'), pages_path, :class => 'links' 5 | = link_to (t :new), new_page_path, :class => 'links' 6 | = link_to (t :edit), edit_page_path(@page), :class => 'links' 7 | = link_to (t :delete), page_path(@page), :method => :delete, :confirm => t(:are_you_sure), :class => 'links' 8 | 9 | 10 | .container_page 11 | .previous_page_button= link_to '', page_path(@previous_page) unless @previous_page == @page 12 | .page{ :id => "page_#{ @page.id }", :style => "width: #{ @page.width }px; height: #{ @page.height }px; background-image: url('#{ @page.image }'); background-color: #{ @page.color }; display: block; position: relative;" } 13 | = render :partial => 'page', :locals => { :page => @page, :partial_htmls => @partial_htmls } 14 | .next_page_button= link_to '', page_path(@next_page) unless @next_page == @page 15 | -------------------------------------------------------------------------------- /salor-hospitality/app/views/guest_types/new.html.haml: -------------------------------------------------------------------------------- 1 | %h2= @guest_type.new_record? ? (t '.new_guest_type') : (t '.edit_guest_type') 2 | 3 | - if @guest_type.errors.any? 4 | .errors 5 | %h3= t 'activerecord.errors.template.header', :count => @guest_type.errors.size, :model => GuestType.model_name.human 6 | %ul 7 | - @guest_type.errors.full_messages.each do |msg| 8 | %li= msg 9 | 10 | .form_fields 11 | = form_for @guest_type do |guest_type_form| 12 | = submit_tag( controller.action_name == 'new' ? (t :create) : (t :edit) ) 13 | .floatright= link_to(t('various.cancel'), guest_types_path, :class => 'links') 14 | .clear 15 | = guest_type_form.label :name 16 | = guest_type_form.text_field :name, :size => '20' 17 | %br 18 | = guest_type_form.label :taxes 19 | = select_tag 'guest_type[taxes_array][]', options_for_select(@taxes.collect{|t| ["#{t.name} (#{t.percent}%)",t.id]}, @selected_taxes), :multiple => true 20 | -------------------------------------------------------------------------------- /salor-hospitality/app/views/sessions/new.html.haml: -------------------------------------------------------------------------------- 1 | #login 2 | - if mobile? 3 | = image_tag "logo-small-#{@branding_codename}.png", :id => 'logo' 4 | = form_tag @submit_path do 5 | %p 6 | = label_tag 'password', (t '.password') 7 | = password_field_tag 'password', '', :size => 9, :class => 'qwerty ui-keyboard-input' 8 | = hidden_field_tag 'mode', 'user' 9 | %span#password_display_keyboard.display_keyboard 10 | %p= submit_tag t('.login'), :class => 'submit' 11 | 12 | - if workstation? 13 | :javascript 14 | $('#password').focus(); 15 | $('#password').keyboard({ 16 | openOn: '', 17 | position: { at: 'center bottom' }, 18 | accepted: function(){ 19 | if ( $('.ui-keyboard-input').val() != "" ) { 20 | $('#login form').submit(); 21 | } 22 | } 23 | }); 24 | $('#password_display_keyboard').click(function() { 25 | $('#password').getkeyboard().reveal(); 26 | }); -------------------------------------------------------------------------------- /salor-hospitality/app/views/exception_notifier/background_exception_notification.html.erb: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | Exception 6 | 7 | 8 |
 9 | <%= @exception.class.to_s =~ /^[aeiou]/i ? 'An' : 'A' %> <%= @exception.class %> occurred in background at <%= raw Time.current %> :
10 | 
11 | <%= @exception.message %>
12 | <%= @backtrace.first %>
13 | <% 
14 |     sections = @sections.map do |section|
15 |       summary = render(section).strip
16 |       unless summary.blank?
17 |         title = render("title", :title => section).strip
18 |         "#{title}\n\n#{summary.gsub(/^/, "  ")}\n\n"
19 |       end
20 |     end.join
21 |     sections = sections.force_encoding('UTF-8').encode('UTF-16', :invalid => :replace).encode('UTF-8') if sections.respond_to?(:force_encoding)
22 | %>
23 | <%= raw sections %>
24 |     
25 | 26 | 27 | -------------------------------------------------------------------------------- /salor-hospitality/app/views/articles/_ingredient.html.haml: -------------------------------------------------------------------------------- 1 | -# The generated HTML code of this partial is inserted into the JS code of the add_ingredient_link helper 2 | -# Note that the statement 'ingredient' represents the name of this partial 3 | 4 | - frm.fields_for :ingredients, ingredient do |f| 5 | %td 6 | = f.label :amount, 'Menge:' 7 | %td 8 | = f.text_field :amount, :size => '3' 9 | 10 | -# Here we need to extract the name of the nested attribute ('new_') in order to make the drop down list set its value in the correct place in the params hash. 11 | - nested_attribute_id = /article\[ingredients_attributes\]\[(.*)\]/.match(f.object_name)[1] 12 | %td 13 | %select{ :id => "article_ingredients_attributes_#{ nested_attribute_id }_stock_id", :name => "article[ingredients_attributes][#{ nested_attribute_id }][stock_id]" } 14 | %option{ :value => '' } 15 | = option_groups_from_collection_for_select @groups, :stocks, :name, :id, :custom_name 16 | -------------------------------------------------------------------------------- /salor-hospitality/app/views/options/index.html.haml: -------------------------------------------------------------------------------- 1 | %h2= t('activerecord.models.option.other') 2 | 3 | - if @current_vendor.categories.existing.any? 4 | = link_to (t :new), new_option_path, :class => 'links' 5 | - else 6 | = t('.no_categories_defined') 7 | 8 | - @categories.each do |c| 9 | - if c.options.existing.any? 10 | %h3= c.name 11 | %ul.sort_options{ :id => "category_#{ c.id }" } 12 | - c.options.existing.active.positioned.each do |o| 13 | %li{ :id => "option_#{ o.id }" } 14 | %span.handle 15 | = link_to o.name, edit_option_path(o), :class => "list_item" 16 | 17 | - @categories.each do |c| 18 | :javascript 19 | $("#category_#{ c.id }").sortable({ 20 | dropOnEmpty: false, handle: '.handle', cursor: 'crosshair', items: 'li', opacity: 0.4, scroll: true, update: function(){ 21 | $.ajax({ type: 'post', data: $('#category_#{ c.id }').sortable('serialize'), dataType: 'script', url: '/options/sort'}) 22 | } 23 | }); 24 | -------------------------------------------------------------------------------- /salor-hospitality/app/views/articles/sort_index.html.haml: -------------------------------------------------------------------------------- 1 | %h2= t '.sort' 2 | 3 | %a.iconbutton.back_button{ :href => '/articles', :title => t(:go_back) } 4 | 5 | - @categories.each do |c| 6 | %h3= c.name 7 | %ul.sort_articles{ :id => "category_#{ c.id }" } 8 | - c.articles.existing.active.positioned.each do |a| 9 | %li{ :id => "article_#{ a.id }" } 10 | %span.handle 11 | = link_to a.name, edit_article_path(a), :class => "list_item" 12 | 13 | - @categories.each do |c| 14 | :javascript 15 | $("#category_#{ c.id }").sortable({ 16 | dropOnEmpty: false, 17 | handle: '.handle', 18 | cursor: 'crosshair', 19 | items: 'li', 20 | opacity: 0.4, 21 | scroll: true, 22 | update: function() { 23 | $.ajax({ 24 | type: 'POST', 25 | data: $('#category_#{ c.id }').sortable('serialize'), 26 | dataType: 'script', 27 | url: '/articles/sort' 28 | }) 29 | } 30 | }); 31 | -------------------------------------------------------------------------------- /salor-hospitality/app/views/payment_methods/new.html.haml: -------------------------------------------------------------------------------- 1 | %h2= @payment_method.new_record? ? (t '.new_payment_method') : (t '.edit_payment_method') 2 | 3 | - if @payment_method.errors.any? 4 | .errors 5 | %h3= t 'activerecord.errors.template.header', :count => @payment_method.errors.size, :model => PaymentMethod.model_name.human 6 | %ul 7 | - @payment_method.errors.full_messages.each do |msg| 8 | %li= msg 9 | 10 | .form_fields 11 | = form_for @payment_method do |payment_method_form| 12 | = submit_tag( controller.action_name == 'new' ? (t :create) : (t :edit) ) 13 | .floatright= link_to(t('various.cancel'), payment_methods_path, :class => 'links') 14 | .clear 15 | = payment_method_form.label :name 16 | = payment_method_form.text_field :name, :size => '10' 17 | %br 18 | = payment_method_form.label :cash 19 | = payment_method_form.check_box :cash 20 | %br 21 | = payment_method_form.label :change 22 | = payment_method_form.check_box :change -------------------------------------------------------------------------------- /salor-hospitality/app/views/surcharges/index.html.haml: -------------------------------------------------------------------------------- 1 | %h2= t('activerecord.models.surcharge.other') 2 | 3 | %p= link_to((t :new), new_surcharge_path, :class => 'links') 4 | 5 | - @seasons.each do |s| 6 | %table.settlements.hotel 7 | %tr 8 | %th 9 | %b= s.name.upcase 10 | - @guest_types.each do |gt| 11 | %th 12 | = gt ? gt.name : t('surcharges.new.common_surcharge') 13 | - @surcharge_names.each do |n| 14 | - next unless n 15 | %tr 16 | %td= n 17 | - @guest_types.each do |gt| 18 | - gt_id = gt ? gt.id : nil 19 | - surcharge_object = @current_vendor.surcharges.existing.where(:season_id => s.id, :guest_type_id => gt_id, :name => n).first 20 | - if surcharge_object 21 | - amount = surcharge_object.amount 22 | %td{:class => "#{'highlighted' if amount.zero?}" }= link_to number_to_currency(amount), edit_surcharge_path(surcharge_object) 23 | - else 24 | %td - 25 | -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/icons/cost_center.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 6 | 9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /salor-hospitality/app/views/stocks/new.html.haml: -------------------------------------------------------------------------------- 1 | %h2= @stock.new_record? ? (t '.new_stock') : (t '.edit_stock') 2 | 3 | = error_messages_for 'stock' 4 | 5 | - form_for @stock do |stock_form| 6 | %table 7 | %tr 8 | %td= stock_form.label('name', Stock.human_attribute_name(:name)) 9 | %td= stock_form.text_field :name, :size => '20' 10 | %tr 11 | %td= stock_form.label('balance', Stock.human_attribute_name(:balance)) 12 | %td= stock_form.text_field :balance, :size => '10' 13 | %tr 14 | %td= stock_form.label('unit', Stock.human_attribute_name(:unit)) 15 | %td 16 | %select{ :id => 'stock_unit', :name => 'stock[unit]' } 17 | = options_for_select MyGlobals::stock_units, @stock.unit 18 | %tr 19 | %td= stock_form.label('group', Group.model_name.human) 20 | %td= stock_form.collection_select :group_id, Group.find(:all), :id, :name, { :include_blank => true } 21 | 22 | %p= submit_tag( controller.action_name == 'new' ? (t :create) : (t :edit) ) 23 | -------------------------------------------------------------------------------- /salor-hospitality/vendor/assets/javascripts/jquery.ui.datepicker-en.js: -------------------------------------------------------------------------------- 1 | /* English/UK initialisation for the jQuery UI date picker plugin. */ 2 | /* Written by Stuart. */ 3 | jQuery(function($){ 4 | $.datepicker.regional['en'] = { 5 | closeText: 'Done', 6 | prevText: 'Prev', 7 | nextText: 'Next', 8 | currentText: 'Today', 9 | monthNames: ['January','February','March','April','May','June', 10 | 'July','August','September','October','November','December'], 11 | monthNamesShort: ['Jan', 'Feb', 'Mar', 'Apr', 'May', 'Jun', 12 | 'Jul', 'Aug', 'Sep', 'Oct', 'Nov', 'Dec'], 13 | dayNames: ['Sunday', 'Monday', 'Tuesday', 'Wednesday', 'Thursday', 'Friday', 'Saturday'], 14 | dayNamesShort: ['Sun', 'Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat'], 15 | dayNamesMin: ['Su','Mo','Tu','We','Th','Fr','Sa'], 16 | weekHeader: 'Wk', 17 | dateFormat: 'yy-mm-dd', 18 | firstDay: 1, 19 | isRTL: false, 20 | showMonthAfterYear: false, 21 | yearSuffix: ''}; 22 | $.datepicker.setDefaults($.datepicker.regional['en']); 23 | }); 24 | -------------------------------------------------------------------------------- /salor-hospitality/vendor/assets/javascripts/jquery.ui.datepicker-tr.js: -------------------------------------------------------------------------------- 1 | /* Turkish initialisation for the jQuery UI date picker plugin. */ 2 | /* Written by Izzet Emre Erkan (kara@karalamalar.net). */ 3 | jQuery(function($){ 4 | $.datepicker.regional['tr'] = { 5 | closeText: 'kapat', 6 | prevText: '<geri', 7 | nextText: 'ileri>', 8 | currentText: 'bugün', 9 | monthNames: ['Ocak','Şubat','Mart','Nisan','Mayıs','Haziran', 10 | 'Temmuz','Ağustos','Eylül','Ekim','Kasım','Aralık'], 11 | monthNamesShort: ['Oca','Şub','Mar','Nis','May','Haz', 12 | 'Tem','Ağu','Eyl','Eki','Kas','Ara'], 13 | dayNames: ['Pazar','Pazartesi','Salı','Çarşamba','Perşembe','Cuma','Cumartesi'], 14 | dayNamesShort: ['Pz','Pt','Sa','Ça','Pe','Cu','Ct'], 15 | dayNamesMin: ['Pz','Pt','Sa','Ça','Pe','Cu','Ct'], 16 | weekHeader: 'Hf', 17 | dateFormat: 'yy-mm-dd', 18 | firstDay: 1, 19 | isRTL: false, 20 | showMonthAfterYear: false, 21 | yearSuffix: ''}; 22 | $.datepicker.setDefaults($.datepicker.regional['tr']); 23 | }); 24 | -------------------------------------------------------------------------------- /salor-hospitality/app/views/stocks/index.html.haml: -------------------------------------------------------------------------------- 1 | %h2= t('activerecord.models.stock.other') 2 | 3 | %p= link_to((t :new), new_stock_path, :class => 'links') if @current_user.role >= 2 4 | 5 | %table 6 | %tr 7 | %th{ :style => 'width:200px' }= Stock.human_attribute_name(:name) 8 | %th{ :style => 'width:80px' }= Stock.human_attribute_name(:balance) 9 | %th{ :style => 'width:100px' }= Stock.human_attribute_name(:unit) 10 | %th{ :style => 'width:150px' }= Stock.human_attribute_name(:group) 11 | %th{ :style => 'width:120px' } 12 | %th{ :style => 'width:120px' } 13 | - @stocks.each do |st| 14 | %tr 15 | %td= st.name 16 | %td{ :style => 'text-align:right;padding-right:20px' }= number_with_precision st.balance 17 | %td= st.unit 18 | %td= Group.find(st.group_id).name if st.group_id? 19 | %td= link_to((t :edit), edit_stock_path(st)) if @current_user.role >= 2 20 | %td= link_to((t :delete), st, :confirm => (t :are_you_sure), :method => :delete) if @current_user.role >= 3 21 | -------------------------------------------------------------------------------- /salor-hospitality/vendor/assets/javascripts/jquery.ui.datepicker-gn.js: -------------------------------------------------------------------------------- 1 | /* German initialisation for the jQuery UI date picker plugin. */ 2 | /* Written by Milian Wolff (mail@milianw.de). */ 3 | jQuery(function($){ 4 | $.datepicker.regional['de'] = { 5 | closeText: 'schließen', 6 | prevText: '<zurück', 7 | nextText: 'Vor>', 8 | currentText: 'heute', 9 | monthNames: ['Januar','Februar','März','April','Mai','Juni', 10 | 'Juli','August','September','Oktober','November','Dezember'], 11 | monthNamesShort: ['Jan','Feb','Mär','Apr','Mai','Jun', 12 | 'Jul','Aug','Sep','Okt','Nov','Dez'], 13 | dayNames: ['Sonntag','Montag','Dienstag','Mittwoch','Donnerstag','Freitag','Samstag'], 14 | dayNamesShort: ['So','Mo','Di','Mi','Do','Fr','Sa'], 15 | dayNamesMin: ['So','Mo','Di','Mi','Do','Fr','Sa'], 16 | weekHeader: 'Wo', 17 | dateFormat: 'yy-mm-dd', 18 | firstDay: 1, 19 | isRTL: false, 20 | showMonthAfterYear: false, 21 | yearSuffix: ''}; 22 | $.datepicker.setDefaults($.datepicker.regional['de']); 23 | }); 24 | -------------------------------------------------------------------------------- /salor-hospitality/public/manifest.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "Salor Hospitality", 3 | "icons": [ 4 | { 5 | "src": "\/android-chrome-36x36.png?v=XBqOjd9jM8", 6 | "sizes": "36x36", 7 | "type": "image\/png", 8 | "density": "0.75" 9 | }, 10 | { 11 | "src": "\/android-chrome-48x48.png?v=XBqOjd9jM8", 12 | "sizes": "48x48", 13 | "type": "image\/png", 14 | "density": "1.0" 15 | }, 16 | { 17 | "src": "\/android-chrome-72x72.png?v=XBqOjd9jM8", 18 | "sizes": "72x72", 19 | "type": "image\/png", 20 | "density": "1.5" 21 | }, 22 | { 23 | "src": "\/android-chrome-96x96.png?v=XBqOjd9jM8", 24 | "sizes": "96x96", 25 | "type": "image\/png", 26 | "density": "2.0" 27 | }, 28 | { 29 | "src": "\/android-chrome-144x144.png?v=XBqOjd9jM8", 30 | "sizes": "144x144", 31 | "type": "image\/png", 32 | "density": "3.0" 33 | }, 34 | { 35 | "src": "\/android-chrome-192x192.png?v=XBqOjd9jM8", 36 | "sizes": "192x192", 37 | "type": "image\/png", 38 | "density": "4.0" 39 | } 40 | ] 41 | } 42 | -------------------------------------------------------------------------------- /salor-hospitality/vendor/assets/javascripts/jquery.ui.datepicker-ru.js: -------------------------------------------------------------------------------- 1 | /* Russian (UTF-8) initialisation for the jQuery UI date picker plugin. */ 2 | /* Written by Andrew Stromnov (stromnov@gmail.com). */ 3 | jQuery(function($){ 4 | $.datepicker.regional['ru'] = { 5 | closeText: 'Закрыть', 6 | prevText: '<Пред', 7 | nextText: 'След>', 8 | currentText: 'Сегодня', 9 | monthNames: ['Январь','Февраль','Март','Апрель','Май','Июнь', 10 | 'Июль','Август','Сентябрь','Октябрь','Ноябрь','Декабрь'], 11 | monthNamesShort: ['Янв','Фев','Мар','Апр','Май','Июн', 12 | 'Июл','Авг','Сен','Окт','Ноя','Дек'], 13 | dayNames: ['воскресенье','понедельник','вторник','среда','четверг','пятница','суббота'], 14 | dayNamesShort: ['вск','пнд','втр','срд','чтв','птн','сбт'], 15 | dayNamesMin: ['Вс','Пн','Вт','Ср','Чт','Пт','Сб'], 16 | weekHeader: 'Не', 17 | dateFormat: 'yy-mm-dd', 18 | firstDay: 1, 19 | isRTL: false, 20 | showMonthAfterYear: false, 21 | yearSuffix: ''}; 22 | $.datepicker.setDefaults($.datepicker.regional['ru']); 23 | }); 24 | -------------------------------------------------------------------------------- /salor-hospitality/vendor/assets/javascripts/jquery.ui.datepicker-pl.js: -------------------------------------------------------------------------------- 1 | /* Polish initialisation for the jQuery UI date picker plugin. */ 2 | /* Written by Jacek Wysocki (jacek.wysocki@gmail.com). */ 3 | jQuery(function($){ 4 | $.datepicker.regional['pl'] = { 5 | closeText: 'Zamknij', 6 | prevText: '<Poprzedni', 7 | nextText: 'Następny>', 8 | currentText: 'Dziś', 9 | monthNames: ['Styczeń','Luty','Marzec','Kwiecień','Maj','Czerwiec', 10 | 'Lipiec','Sierpień','Wrzesień','Październik','Listopad','Grudzień'], 11 | monthNamesShort: ['Sty','Lu','Mar','Kw','Maj','Cze', 12 | 'Lip','Sie','Wrz','Pa','Lis','Gru'], 13 | dayNames: ['Niedziela','Poniedzialek','Wtorek','Środa','Czwartek','Piątek','Sobota'], 14 | dayNamesShort: ['Nie','Pn','Wt','Śr','Czw','Pt','So'], 15 | dayNamesMin: ['N','Pn','Wt','Śr','Cz','Pt','So'], 16 | weekHeader: 'Tydz', 17 | dateFormat: 'yy-mm-dd', 18 | firstDay: 1, 19 | isRTL: false, 20 | showMonthAfterYear: false, 21 | yearSuffix: ''}; 22 | $.datepicker.setDefaults($.datepicker.regional['pl']); 23 | }); 24 | -------------------------------------------------------------------------------- /salor-hospitality/app/views/roles/index.html.haml: -------------------------------------------------------------------------------- 1 | %h2= t('activerecord.models.role.other') 2 | 3 | %p= link_to((t :new), new_role_path, :class => 'links') 4 | 5 | %table 6 | %tr 7 | %th{:style => "width: 120px"}= Role.human_attribute_name :name 8 | %th{:style => "width: 100px; text-align: center"}= Role.human_attribute_name :weight 9 | %th= t "activerecord.models.user.other" 10 | %th 11 | %tr 12 | - @roles.each do |r| 13 | %tr 14 | %td= link_to r.name, edit_role_path(r), :class => "list_item" 15 | %td{:style => "text-align: center" }= r.weight 16 | %td= r.users.existing.collect { |u| u.login }.join(", ") 17 | %td 18 | - if @current_company.users.existing.where(:role_id => r.id).any? 19 | = image_tag 'button_small_delete.png' 20 | - else 21 | = link_to(image_tag('button_small_delete.png', :title => Role.human_attribute_name(:hidden), :alt => Role.human_attribute_name(:hidden), :style => "vertical-align:bottom;padding-top:5px;"), role_path(r), :method => :delete, :confirm => t(:are_you_sure)) 22 | -------------------------------------------------------------------------------- /salor-hospitality/vendor/assets/javascripts/jquery.ui.datepicker-fr.js: -------------------------------------------------------------------------------- 1 | /* French initialisation for the jQuery UI date picker plugin. */ 2 | /* Written by Keith Wood (kbwood{at}iinet.com.au) and Stéphane Nahmani (sholby@sholby.net). */ 3 | jQuery(function($){ 4 | $.datepicker.regional['fr'] = { 5 | closeText: 'Fermer', 6 | prevText: '<Préc', 7 | nextText: 'Suiv>', 8 | currentText: 'Courant', 9 | monthNames: ['Janvier','Février','Mars','Avril','Mai','Juin', 10 | 'Juillet','Août','Septembre','Octobre','Novembre','Décembre'], 11 | monthNamesShort: ['Jan','Fév','Mar','Avr','Mai','Jun', 12 | 'Jul','Aoû','Sep','Oct','Nov','Déc'], 13 | dayNames: ['Dimanche','Lundi','Mardi','Mercredi','Jeudi','Vendredi','Samedi'], 14 | dayNamesShort: ['Dim','Lun','Mar','Mer','Jeu','Ven','Sam'], 15 | dayNamesMin: ['Di','Lu','Ma','Me','Je','Ve','Sa'], 16 | weekHeader: 'Sm', 17 | dateFormat: 'yy-mm-dd', 18 | firstDay: 1, 19 | isRTL: false, 20 | showMonthAfterYear: false, 21 | yearSuffix: ''}; 22 | $.datepicker.setDefaults($.datepicker.regional['fr']); 23 | }); 24 | -------------------------------------------------------------------------------- /salor-hospitality/app/views/users/_logins_table.html.haml: -------------------------------------------------------------------------------- 1 | #user_logins 2 | %table 3 | %tr 4 | %th 5 | %th 6 | %th= UserLogin.human_attribute_name(:duration) 7 | - duration_sum = 0 8 | - user_logins.each do |ul| 9 | - duration_sum += ul.duration if ul.logout 10 | %tr{ :class => "#{ 'total' if ul.logout }" } 11 | %td.left= ul.login ? "#{ UserLogin.human_attribute_name(:login) } ▶" : "◁ #{ UserLogin.human_attribute_name(:logout) }" 12 | %td= l((ul.login ? ul.login: ul.logout), :format => :long) 13 | %td= UserLogin.duration_formatted(ul.duration.to_i) if ul.logout 14 | - if ul == last_login and ul.logout.nil? 15 | %tr.total{ :style => 'color:green' } 16 | %td 17 | %td== #{ t '.on_duty' }... 18 | - on_duty_mins = (Time.now - ul.login).to_i / 60 19 | - duration_sum += on_duty_mins 20 | %td= UserLogin.duration_formatted(on_duty_mins) 21 | %tr 22 | %td 23 | %td 24 | %td{ :style => "font-size: 150%" }= UserLogin.duration_formatted(duration_sum) -------------------------------------------------------------------------------- /salor-hospitality/vendor/assets/javascripts/jquery.ui.datepicker-es.js: -------------------------------------------------------------------------------- 1 | /* Inicialización en español para la extensión 'UI date picker' para jQuery. */ 2 | /* Traducido por Vester (xvester@gmail.com). */ 3 | jQuery(function($){ 4 | $.datepicker.regional['es'] = { 5 | closeText: 'Cerrar', 6 | prevText: '<Ant', 7 | nextText: 'Sig>', 8 | currentText: 'Hoy', 9 | monthNames: ['Enero','Febrero','Marzo','Abril','Mayo','Junio', 10 | 'Julio','Agosto','Septiembre','Octubre','Noviembre','Diciembre'], 11 | monthNamesShort: ['Ene','Feb','Mar','Abr','May','Jun', 12 | 'Jul','Ago','Sep','Oct','Nov','Dic'], 13 | dayNames: ['Domingo','Lunes','Martes','Miércoles','Jueves','Viernes','Sábado'], 14 | dayNamesShort: ['Dom','Lun','Mar','Mié','Juv','Vie','Sáb'], 15 | dayNamesMin: ['Do','Lu','Ma','Mi','Ju','Vi','Sá'], 16 | weekHeader: 'Sm', 17 | dateFormat: 'yy-mm-dd', 18 | firstDay: 1, 19 | isRTL: false, 20 | showMonthAfterYear: false, 21 | yearSuffix: ''}; 22 | $.datepicker.setDefaults($.datepicker.regional['es']); 23 | }); 24 | -------------------------------------------------------------------------------- /salor-hospitality/vendor/assets/javascripts/jquery.ui.datepicker-it.js: -------------------------------------------------------------------------------- 1 | /* Italian initialisation for the jQuery UI date picker plugin. */ 2 | /* Written by Antonello Pasella (antonello.pasella@gmail.com). */ 3 | jQuery(function($){ 4 | $.datepicker.regional['it'] = { 5 | closeText: 'Chiudi', 6 | prevText: '<Prec', 7 | nextText: 'Succ>', 8 | currentText: 'Oggi', 9 | monthNames: ['Gennaio','Febbraio','Marzo','Aprile','Maggio','Giugno', 10 | 'Luglio','Agosto','Settembre','Ottobre','Novembre','Dicembre'], 11 | monthNamesShort: ['Gen','Feb','Mar','Apr','Mag','Giu', 12 | 'Lug','Ago','Set','Ott','Nov','Dic'], 13 | dayNames: ['Domenica','Lunedì','Martedì','Mercoledì','Giovedì','Venerdì','Sabato'], 14 | dayNamesShort: ['Dom','Lun','Mar','Mer','Gio','Ven','Sab'], 15 | dayNamesMin: ['Do','Lu','Ma','Me','Gi','Ve','Sa'], 16 | weekHeader: 'Sm', 17 | dateFormat: 'yy-mm-dd', 18 | firstDay: 1, 19 | isRTL: false, 20 | showMonthAfterYear: false, 21 | yearSuffix: ''}; 22 | $.datepicker.setDefaults($.datepicker.regional['it']); 23 | }); 24 | -------------------------------------------------------------------------------- /salor-hospitality/app/views/cost_centers/new.html.haml: -------------------------------------------------------------------------------- 1 | %h2= @cost_center.new_record? ? (t '.new_cost_center') : (t '.edit_cost_center') 2 | 3 | - if @cost_center.errors.any? 4 | .errors 5 | %h3= t 'activerecord.errors.template.header', :count => @cost_center.errors.size, :model => CostCenter.model_name.human 6 | %ul 7 | - @cost_center.errors.full_messages.each do |msg| 8 | %li= msg 9 | 10 | .form_fields 11 | = form_for @cost_center do |cost_center_form| 12 | = submit_tag( controller.action_name == 'new' ? (t :create) : (t :edit) ) 13 | .floatright= link_to(t('various.cancel'), cost_centers_path, :class => 'links') 14 | .clear 15 | %table 16 | %tr 17 | %td= cost_center_form.label 'name' 18 | %td= cost_center_form.text_field :name, :size => '10' 19 | %tr 20 | %td= cost_center_form.label 'description' 21 | %td= cost_center_form.text_field :description, :size => '20' 22 | %tr 23 | %td= cost_center_form.label 'no_payment_methods' 24 | %td= cost_center_form.check_box :no_payment_methods 25 | -------------------------------------------------------------------------------- /salor-hospitality/vendor/assets/javascripts/jquery.ui.datepicker-el.js: -------------------------------------------------------------------------------- 1 | /* Greek (el) initialisation for the jQuery UI date picker plugin. */ 2 | /* Written by Alex Cicovic (http://www.alexcicovic.com) */ 3 | jQuery(function($){ 4 | $.datepicker.regional['el'] = { 5 | closeText: 'Κλείσιμο', 6 | prevText: 'Προηγούμενος', 7 | nextText: 'Επόμενος', 8 | currentText: 'Τρέχων Μήνας', 9 | monthNames: ['Ιανουάριος','Φεβρουάριος','Μάρτιος','Απρίλιος','Μάιος','Ιούνιος', 10 | 'Ιούλιος','Αύγουστος','Σεπτέμβριος','Οκτώβριος','Νοέμβριος','Δεκέμβριος'], 11 | monthNamesShort: ['Ιαν','Φεβ','Μαρ','Απρ','Μαι','Ιουν', 12 | 'Ιουλ','Αυγ','Σεπ','Οκτ','Νοε','Δεκ'], 13 | dayNames: ['Κυριακή','Δευτέρα','Τρίτη','Τετάρτη','Πέμπτη','Παρασκευή','Σάββατο'], 14 | dayNamesShort: ['Κυρ','Δευ','Τρι','Τετ','Πεμ','Παρ','Σαβ'], 15 | dayNamesMin: ['Κυ','Δε','Τρ','Τε','Πε','Πα','Σα'], 16 | weekHeader: 'Εβδ', 17 | dateFormat: 'yy-mm-dd', 18 | firstDay: 1, 19 | isRTL: false, 20 | showMonthAfterYear: false, 21 | yearSuffix: ''}; 22 | $.datepicker.setDefaults($.datepicker.regional['el']); 23 | }); 24 | -------------------------------------------------------------------------------- /salor-hospitality/vendor/assets/javascripts/jquery.ui.datepicker-hu.js: -------------------------------------------------------------------------------- 1 | /* Hungarian initialisation for the jQuery UI date picker plugin. */ 2 | /* Written by Istvan Karaszi (jquery@spam.raszi.hu). */ 3 | jQuery(function($){ 4 | $.datepicker.regional['hu'] = { 5 | closeText: 'bezárás', 6 | prevText: '« vissza', 7 | nextText: 'előre »', 8 | currentText: 'ma', 9 | monthNames: ['Január', 'Február', 'Március', 'Április', 'Május', 'Június', 10 | 'Július', 'Augusztus', 'Szeptember', 'Október', 'November', 'December'], 11 | monthNamesShort: ['Jan', 'Feb', 'Már', 'Ápr', 'Máj', 'Jún', 12 | 'Júl', 'Aug', 'Szep', 'Okt', 'Nov', 'Dec'], 13 | dayNames: ['Vasárnap', 'Hétfö', 'Kedd', 'Szerda', 'Csütörtök', 'Péntek', 'Szombat'], 14 | dayNamesShort: ['Vas', 'Hét', 'Ked', 'Sze', 'Csü', 'Pén', 'Szo'], 15 | dayNamesMin: ['V', 'H', 'K', 'Sze', 'Cs', 'P', 'Szo'], 16 | weekHeader: 'Hé', 17 | dateFormat: 'yy-mm-dd', 18 | firstDay: 1, 19 | isRTL: false, 20 | showMonthAfterYear: false, 21 | yearSuffix: ''}; 22 | $.datepicker.setDefaults($.datepicker.regional['hu']); 23 | }); 24 | -------------------------------------------------------------------------------- /salor-hospitality/app/assets/javascripts/menucard_slideshow.js: -------------------------------------------------------------------------------- 1 | var ran_documentready_menucard_slideshow = false; 2 | 3 | $(function() { 4 | if (ran_documentready_menucard_slideshow) return; 5 | 6 | if (page_count == 1) { 7 | $('#page_' + page_ids[0]).fadeIn(1000); 8 | } else { 9 | // kick-off self-calling slide function 10 | show_page(0, page_count - 1); 11 | } 12 | ran_documentready_menucard_slideshow = true; 13 | }) 14 | 15 | function show_page(idx, last_idx) { 16 | var time_fadein = 1000; 17 | var time_display = 6000; 18 | 19 | var page = $('#page_' + page_ids[idx]); 20 | page.css('z-index', 100); 21 | page.fadeIn(time_fadein, function() { 22 | var last_page = $('#page_' + page_ids[last_idx]); 23 | last_page.fadeOut(time_fadein, function() { 24 | page.css('z-index', 99); 25 | last_page.hide(); 26 | }); 27 | 28 | }); 29 | 30 | if (idx == (page_count - 1)) { 31 | //wrap to first page 32 | next_idx = 0 33 | } else { 34 | next_idx = idx + 1; 35 | } 36 | 37 | setTimeout(function(){ 38 | show_page(next_idx, idx); 39 | }, time_display); 40 | } -------------------------------------------------------------------------------- /salor-hospitality/app/views/exception_notifier/exception_notification.text.erb: -------------------------------------------------------------------------------- 1 | <%= @exception.class.to_s =~ /^[aeiou]/i ? 'An' : 'A' %> <%= @exception.class %> occurred in <%= @kontroller.controller_name %>#<%= @kontroller.action_name %>: 2 | 3 | <%= raw @exception.message %> 4 | <%= raw @backtrace.first %> 5 | 6 | <% 7 | sections = @sections.map do |section| 8 | begin 9 | summary = render(section).strip 10 | unless summary.blank? 11 | title = render("title", :title => section).strip 12 | "#{title}\n\n#{summary.gsub(/^/, " ")}\n\n" 13 | end 14 | 15 | rescue Exception => e 16 | title = render("title", :title => section).strip 17 | summary = ["ERROR: Failed to generate exception summary:", [e.class.to_s, e.message].join(": "), e.backtrace && e.backtrace.join("\n")].compact.join("\n\n") 18 | 19 | [title, summary.gsub(/^/, " "), nil].join("\n\n") 20 | end 21 | end.join 22 | sections = sections.force_encoding('UTF-8').encode('UTF-16', :invalid => :replace).encode('UTF-8') if sections.respond_to?(:force_encoding) 23 | %> 24 | 25 | <%= raw sections %> 26 | -------------------------------------------------------------------------------- /salor-hospitality/lib/escper/escper.rb: -------------------------------------------------------------------------------- 1 | require 'rmagick' 2 | require 'yaml' 3 | require 'timeout' 4 | 5 | dir = File.dirname(__FILE__) 6 | Dir[File.expand_path("#{dir}/escper/*.rb")].uniq.each do |file| 7 | require file 8 | end 9 | 10 | module Escper 11 | #mattr_accessor :codepage_file, :use_safe_device_path, :safe_device_path 12 | 13 | def self.codepage_file 14 | @@codepage_file 15 | end 16 | 17 | def self.codepage_file=(codepage_file) 18 | @@codepage_file = codepage_file 19 | end 20 | 21 | def self.use_safe_device_path 22 | @@use_safe_device_path 23 | end 24 | 25 | def self.use_safe_device_path=(use_safe_device_path) 26 | @@use_safe_device_path = use_safe_device_path 27 | end 28 | 29 | def self.safe_device_path 30 | @@safe_device_path 31 | end 32 | 33 | def self.safe_device_path=(safe_device_path) 34 | @@safe_device_path = safe_device_path 35 | end 36 | 37 | @@codepage_file = File.join(File.dirname(__FILE__), 'escper', 'codepages.yml') 38 | @@use_safe_device_path = false 39 | @@safe_device_path = File.join('/','tmp') 40 | 41 | def self.setup 42 | yield self 43 | end 44 | end 45 | -------------------------------------------------------------------------------- /salor-hospitality/app/models/camera.rb: -------------------------------------------------------------------------------- 1 | class Camera < ActiveRecord::Base 2 | include Scope 3 | include Base 4 | 5 | belongs_to :vendor 6 | belongs_to :company 7 | 8 | validates_presence_of :name 9 | validates_presence_of :url_stream 10 | validates_presence_of :url_snapshot 11 | validates_presence_of :host_internal 12 | validates_presence_of :port 13 | 14 | def resource(ip, mode='stream') 15 | match = /^(.*?)\.(.*?)\..*/.match(ip) 16 | if match.length == 3 17 | space = match[0] + '.' + match[1] 18 | else 19 | return "blank.gif" 20 | end 21 | if match[1] == "192" or match[1] == "10" or match[1] == "127" or (match[1] == "172" and match[2].to_i >= 16) 22 | user_location = :internal 23 | else 24 | user_location = :external 25 | end 26 | 27 | url_method = "url_" + mode 28 | if user_location == :internal 29 | return "#{ self.host_internal }:#{ self.port }#{ self.send(url_method) }" 30 | elsif user_location == :external 31 | return "#{ self.host_external }:#{ self.port }#{ self.send(url_method) }" 32 | else 33 | return "blank.gif" 34 | end 35 | end 36 | end 37 | -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/icons/surcharge.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 6 | 9 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /salor-hospitality/app/assets/stylesheets/iframe.sass: -------------------------------------------------------------------------------- 1 | body 2 | :font-size 85% 3 | :padding 0px 4 | :margin 0px 5 | 6 | div.partial 7 | :position absolute 8 | 9 | div.page 10 | :width 100% 11 | :height 100% 12 | :background-repeat no-repeat 13 | :position absolute 14 | :display none 15 | :float left 16 | img 17 | :-moz-box-shadow 0px 0px 8px black 18 | :-moz-border-radius 10px 19 | :-webkit-box-shadow 0px 0px 8px black 20 | :-webkit-border-radius 10px 21 | span 22 | :display inline-block 23 | :background-repeat no-repeat 24 | span.dmc_button 25 | :display none 26 | 27 | div.previous_page_button, 28 | div.next_page_button 29 | :float left 30 | :height 400px 31 | :width 50px 32 | :margin 0 10px 33 | 34 | div.previous_page_button a, 35 | div.next_page_button a 36 | :color black 37 | :display block 38 | :height 400px 39 | :width 50px 40 | :background-repeat no-repeat 41 | :background-position center center 42 | 43 | div.next_page_button a 44 | :background-image url('/images/arrow_page_right.png') 45 | 46 | div.previous_page_button a 47 | :background-image url('/images/arrow_page_left.png') 48 | -------------------------------------------------------------------------------- /salor-hospitality/app/views/orders/render_order_form.js.erb: -------------------------------------------------------------------------------- 1 | //views/render_order_form.js.erb 2 | <% if @order %> 3 | items_json = <%= raw @order.items_to_json %>; 4 | submit_json.id = <%= @order.id %>; 5 | 6 | $('#order_info').html('<%= escape_javascript Order.model_name.human %> ID <%= @order.id %> <%= escape_javascript @order.table.name %> (<%= escape_javascript @order.user_login %>) <%= escape_javascript @order.customer.full_name if @order.customer %>'); 7 | 8 | $('#order_info_bottom').html('<%= escape_javascript Order.model_name.human %> ID <%= @order.id %> <%= escape_javascript @order.table.name %> (<%= escape_javascript @order.user_login %>) <%= escape_javascript @order.customer.full_name if @order.customer %>'); 9 | 10 | $('#order_note').val('<%= escape_javascript @order.note %>'); 11 | 12 | $('#order_sum').val('<%= number_with_precision(@order.sum, :precision => 2) %>'); 13 | 14 | <% else %> 15 | $('#order_info').html('<%= escape_javascript t('orders.order.new') %> <%= escape_javascript @table.name %>'); 16 | 17 | $('#order_info_bottom').html('<%= escape_javascript t('orders.order.new') %> <%= escape_javascript @table.name %>'); 18 | <% end %> -------------------------------------------------------------------------------- /salor-hospitality/lib/escper/escper/vendor_printer.rb: -------------------------------------------------------------------------------- 1 | module Escper 2 | class VendorPrinter 3 | 4 | def initialize(attrs) 5 | @name = attrs[:name] 6 | @path = attrs[:path] 7 | @copies = attrs[:copies] 8 | @codepage = attrs[:codepage] 9 | @baudrate = attrs[:baudrate] 10 | @baudrate ||= 9600 11 | @id = attrs[:id] 12 | end 13 | 14 | def name 15 | @name 16 | end 17 | 18 | def name=(name) 19 | @name = name 20 | end 21 | 22 | def path 23 | @path 24 | end 25 | 26 | def path=(path) 27 | @path = path 28 | end 29 | 30 | def copies 31 | @copies 32 | end 33 | 34 | def copies=(copies) 35 | @copies = copies 36 | end 37 | 38 | def codepage 39 | @codepage 40 | end 41 | 42 | def codepage=(codepage) 43 | @codepage = codepage 44 | end 45 | 46 | def baudrate 47 | @baudrate 48 | end 49 | 50 | def baudrate=(baudrate) 51 | @baudrate = baudrate 52 | end 53 | 54 | def id 55 | @id 56 | end 57 | 58 | def id=(id) 59 | @id = id 60 | end 61 | end 62 | end -------------------------------------------------------------------------------- /debian/salor-hospitality.templates: -------------------------------------------------------------------------------- 1 | Template: salor-hospitality/old-instances 2 | Type: string 3 | Description: Salor Hospitality instances to be deconfigured: 4 | Configuration files for these instances will be removed. 5 | . 6 | Database (de)configuration will be asked accordingly. 7 | 8 | Template: salor-hospitality/current-instances 9 | Type: string 10 | Default: default 11 | Description: Salor Hospitality instances to be configured or upgraded: 12 | Space-separated list of instances identifiers. 13 | . 14 | Each instance has its configuration files in /etc/salor-hospitality// 15 | . 16 | To deconfigure an instance, remove its identifier from this list. 17 | 18 | Template: salor-hospitality/user 19 | Type: select 20 | Choices: ${availableUsers} 21 | Default: www-data 22 | Description: User to run the Salor Hospitality Rails application with. 23 | Salor Hospitality can write files to your Desktop and supports to share your Desktop screen in combination with the remotesupport package. For this to work, the application must run as the user you are working with normally. If you are not going to use Salor Hospitality as a desktop application, but provide it as a Software as a Service, it is recommended to leave the default, www-data. -------------------------------------------------------------------------------- /salor-hospitality/app/views/orders/_functions_header_index.haml: -------------------------------------------------------------------------------- 1 | - if permit('manage_business_invoice') and not mobile_special? 2 | %a.iconbutton.last_invoice_button{ :href => "/orders/last", :title => t('.show_last_order'), :style => branding_override_style(:buttons, :last_invoice) } 3 | - if permit('manage_hotel') 4 | %a.iconbutton.last_invoice_hotel_button{ :href => "/bookings/last", :title => t('.show_last_booking') } 5 | 6 | - if mobile_special? 7 | = link_to '', '/orders/last_invoices', :remote => true, :class => 'iconbutton invoice_button' 8 | 9 | - if permit('see_item_notifications_user_delivery') or permit('see_item_notifications_user_preparation') or permit('see_item_notifications_vendor_delivery') or permit('see_item_notifications_vendor_preparation') 10 | %a.iconbutton.items_notifications_button{ :onclick => 'display_items_notifications()', :title => t('.items_notifications') } 11 | 12 | - if permit('move_tables') 13 | %a.iconbutton.tables2_button{ :onclick => "toggle_drag_tables();", :title => t('.toggle_drag_tables') } 14 | 15 | %a.iconbutton.logout_button{ :onclick => "logout()" } 16 | 17 | - if permit('allow_exit') 18 | %a#exit_button.iconbutton.exit_button{ :onclick => "window.open('', '_self', ''); window.close();", :title => t('.exit') } -------------------------------------------------------------------------------- /salor-hospitality/app/models/cash_register.rb: -------------------------------------------------------------------------------- 1 | # Copyright (c) 2012 Red (E) Tools Ltd. 2 | # 3 | # Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: 4 | # 5 | # The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. 6 | # 7 | # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 8 | 9 | class CashRegister < ActiveRecord::Base 10 | include Scope 11 | include Base 12 | 13 | belongs_to :company 14 | belongs_to :vendor 15 | end 16 | -------------------------------------------------------------------------------- /salor-hospitality/app/models/coupon.rb: -------------------------------------------------------------------------------- 1 | # coding: UTF-8 2 | 3 | # Copyright (c) 2012 Red (E) Tools Ltd. 4 | # 5 | # Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: 6 | # 7 | # The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. 8 | # 9 | # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 10 | 11 | class Coupon < ActiveRecord::Base 12 | include Scope 13 | include Base 14 | 15 | belongs_to :company 16 | belongs_to :vendor 17 | end 18 | -------------------------------------------------------------------------------- /salor-hospitality/app/views/seasons/new.html.haml: -------------------------------------------------------------------------------- 1 | %h2= @season.new_record? ? (t '.new_season') : (t '.edit_season') 2 | 3 | - if @season.errors.any? 4 | .errors 5 | %h3= t 'activerecord.errors.template.header', :count => @season.errors.size, :model => Season.model_name.human 6 | %ul 7 | - @season.errors.full_messages.each do |msg| 8 | %li= msg 9 | 10 | .form_fields 11 | = form_for @season do |season_form| 12 | = submit_tag( controller.action_name == 'new' ? (t :create) : (t :edit) ) 13 | .floatright= link_to(t('various.cancel'), seasons_path, :class => 'links') 14 | .clear 15 | %table 16 | %tr 17 | %td= season_form.label :name 18 | %td= season_form.text_field :name, :size => '20' 19 | %tr 20 | %td= season_form.label :from_date 21 | %td= season_form.date_select :from_date, :size => '20' 22 | %tr 23 | %td= season_form.label :to_date 24 | %td= season_form.date_select :to_date, :size => '20' 25 | %tr 26 | %td= season_form.label :color 27 | %td= season_form.text_field :color, :size => '20' 28 | 29 | :javascript 30 | $("#season_color").colpick({ 31 | onSubmit: function(hsb, hex, rgb, el, by_set_color) { 32 | $("#season_color").val("#" + hex); 33 | } 34 | }); -------------------------------------------------------------------------------- /salor-hospitality/app/models/cash_drawer.rb: -------------------------------------------------------------------------------- 1 | # Copyright (c) 2012 Red (E) Tools Ltd. 2 | # 3 | # Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: 4 | # 5 | # The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. 6 | # 7 | # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 8 | 9 | class CashDrawer < ActiveRecord::Base 10 | include Scope 11 | include Base 12 | 13 | belongs_to :company 14 | belongs_to :vendor 15 | belongs_to :user 16 | end 17 | -------------------------------------------------------------------------------- /salor-hospitality/app/models/discount.rb: -------------------------------------------------------------------------------- 1 | # coding: UTF-8 2 | 3 | # Copyright (c) 2012 Red (E) Tools Ltd. 4 | # 5 | # Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: 6 | # 7 | # The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. 8 | # 9 | # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 10 | 11 | class Discount < ActiveRecord::Base 12 | include Scope 13 | include Base 14 | 15 | belongs_to :company 16 | belongs_to :vendor 17 | end 18 | -------------------------------------------------------------------------------- /salor-hospitality/lib/escper/escper/asciifier.rb: -------------------------------------------------------------------------------- 1 | module Escper 2 | class Asciifier 3 | def initialize(codepage=0) 4 | @codepage = codepage 5 | @codepage_lookup_yaml = YAML::load(File.read(Escper.codepage_file)) 6 | end 7 | 8 | def self.all_chars 9 | out = "\e@" # Initialize Printer 10 | out.encode!('ASCII-8BIT') 11 | 33.upto(255) { |i| out += i.to_s(16) + i.chr + ' ' } 12 | return out 13 | end 14 | 15 | def process(text) 16 | output = '' 17 | output.encode 'ASCII-8BIT' 18 | 0.upto(text.length - 1) do |i| 19 | char_utf8 = text[i] 20 | char_ascii = text[i].force_encoding('ASCII-8BIT') 21 | if char_ascii.length == 1 22 | output += char_ascii 23 | else 24 | output += codepage_lookup(char_utf8) 25 | end 26 | end 27 | return output 28 | end 29 | 30 | def codepage_lookup(char) 31 | return '*'.force_encoding('ASCII-8BIT') unless @codepage_lookup_yaml[@codepage] 32 | 33 | output = @codepage_lookup_yaml[@codepage][char] 34 | if output 35 | output = output.chr 36 | else 37 | output = '?' 38 | end 39 | return output.force_encoding('ASCII-8BIT') 40 | end 41 | 42 | end 43 | end -------------------------------------------------------------------------------- /salor-hospitality/app/models/reservation.rb: -------------------------------------------------------------------------------- 1 | # coding: UTF-8 2 | 3 | # Copyright (c) 2012 Red (E) Tools Ltd. 4 | # 5 | # Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: 6 | # 7 | # The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. 8 | # 9 | # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 10 | 11 | class Reservation < ActiveRecord::Base 12 | include Scope 13 | include Base 14 | 15 | belongs_to :company 16 | belongs_to :vendor 17 | end 18 | -------------------------------------------------------------------------------- /salor-hospitality/app/assets/javascripts/audio.js: -------------------------------------------------------------------------------- 1 | var audio_enabled_count = 0; 2 | 3 | function enable_audio() { 4 | if (audio_enabled_count < 2) { 5 | try { 6 | document.getElementById('audio').load(); 7 | } 8 | 9 | catch (err) { 10 | // not supported by salor-bin 11 | } 12 | debug('enable_audio called ' + audio_enabled_count); 13 | audio_enabled_count += 1; 14 | } 15 | } 16 | 17 | $(function(){ 18 | enable_audio(); 19 | 20 | jQuery.ajaxSetup({ 21 | 'beforeSend': function(xhr) { 22 | //xhr.setRequestHeader("Accept", "text/javascript"); 23 | xhr.setRequestHeader('X-CSRF-Token', $('meta[name="csrf-token"]').attr('content')); 24 | } 25 | }) 26 | 27 | $(window).keydown(function(e){ 28 | for (var key in _key_codes) { 29 | if (e.keyCode == _key_codes[key]) { 30 | _keys_down[key] = true; 31 | } 32 | } 33 | }); 34 | 35 | $(window).keyup(function(e){ 36 | for (var key in _key_codes) { 37 | if (e.keyCode == _key_codes[key]) { 38 | _keys_down[key] = false; 39 | } 40 | } 41 | }); 42 | }) 43 | 44 | function alert_audio() { 45 | try { 46 | document.getElementById('audio').play(); 47 | } 48 | 49 | catch(err) { 50 | // not supported by salor-bin 51 | } 52 | } -------------------------------------------------------------------------------- /salor-hospitality/app/models/room_type.rb: -------------------------------------------------------------------------------- 1 | # Copyright (c) 2012 Red (E) Tools Ltd. 2 | # 3 | # Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: 4 | # 5 | # The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. 6 | # 7 | # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 8 | 9 | class RoomType < ActiveRecord::Base 10 | include Scope 11 | include Base 12 | 13 | belongs_to :vendor 14 | belongs_to :company 15 | has_many :room_prices 16 | has_many :rooms 17 | end 18 | -------------------------------------------------------------------------------- /salor-hospitality/app/assets/javascripts/keyboard.js: -------------------------------------------------------------------------------- 1 | function enable_keyboard_for_items(item_designator) { 2 | $('input#comment_for_item_' + item_designator).keyboard({ 3 | openOn: '', 4 | visible: function(){ 5 | $('.ui-keyboard-input').select(); 6 | }, 7 | accepted: function() { 8 | add_comment_to_item(item_designator); 9 | } 10 | }); 11 | $('#comment_for_item_' + item_designator + '_display_keyboard').click(function(){ 12 | $('input#comment_for_item_' + item_designator).getkeyboard().reveal(); 13 | }); 14 | $('input#price_for_item_' + item_designator).keyboard({ 15 | openOn: '', 16 | layout: 'num', 17 | visible: function(){ 18 | $('.ui-keyboard-input').select(); 19 | }, 20 | accepted: function() { 21 | add_price_to_item(item_designator); 22 | } 23 | }); 24 | $('#price_for_item_' + item_designator + '_display_keyboard').click(function(){ 25 | $('input#price_for_item_' + item_designator).getkeyboard().reveal(); 26 | }); 27 | } 28 | 29 | function catch_keypress(d,type) { 30 | if (event.keyCode == 27) { 31 | // Escape 32 | } else if (event.keyCode == 13) { 33 | // Enter 34 | if (type == 'comment') { 35 | add_comment_to_item(d); 36 | } else if (type == 'price') { 37 | add_price_to_item(d); 38 | } 39 | } 40 | } -------------------------------------------------------------------------------- /salor-hospitality/db/migrate/20150709092112_add_item_types.rb: -------------------------------------------------------------------------------- 1 | class AddItemTypes < ActiveRecord::Migration 2 | def up 3 | Article.reset_column_information 4 | Item.reset_column_information 5 | begin 6 | 7 | Vendor.where(:hidden => nil).each do |v| 8 | # This will only be effective on an already seeded database... 9 | puts "-- Creating ItemTypes for Vendor #{ v.id }..." 10 | unless v.item_types.any? 11 | # ... and only when no ItemTypes exist yet 12 | behaviors = ["normal", "gift_card", "coupon"] 13 | behaviors.each do |b| 14 | it = ItemType.new 15 | it.vendor = v 16 | it.company = v.company 17 | it.behavior = b 18 | it.name = I18n.t "item_type_names.#{ b }", :locale => v.get_region.to_s[0..1] 19 | res = it.save 20 | puts "Created ItemType #{ it.id } with behavior #{ b }" 21 | if res == true and b == "normal" 22 | puts "Setting all Articles to Item Type 'normal' with ItemType ID #{ it.id }" 23 | v.articles.existing.update_all :item_type_id => it.id 24 | end 25 | 26 | end 27 | end 28 | end 29 | rescue Exception => e 30 | puts "Exception #{ e } during creation of ItemTypes." 31 | end 32 | end 33 | 34 | def down 35 | end 36 | end 37 | -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/icons/wallet.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 6 | 8 | 11 | 12 | 14 | 15 | 16 | -------------------------------------------------------------------------------- /debian/control: -------------------------------------------------------------------------------- 1 | Source: salor-hospitality 2 | Section: ruby 3 | Priority: extra 4 | Maintainer: Michael Franzl 5 | Build-Depends: debhelper (>= 8.0.0), po-debconf 6 | Standards-Version: 3.9.3 7 | Homepage: http://thebigrede.net 8 | #Vcs-Git: git://github.com/michaelfranzl/SalorHospitality.git 9 | #Vcs-Browser: https://github.com/michaelfranzl/SalorHospitality 10 | 11 | Package: salor-hospitality 12 | Architecture: all 13 | Pre-Depends: dbconfig-common, sudo 14 | Depends: ${misc:Depends}, debconf, mysql-server, udev, nodejs, ruby, libruby, ruby-dev, rake, libmysqld-dev, libmysqlclient-dev, libmagickwand-dev, libmagickcore-dev, libxslt1-dev, bundler 15 | Suggests: vim, apt-show-versions, remotesupport, salor-bin, exim4, isc-dhcp-server, expect, ssh, x11vnc, bind9, chromium-browser, salor-helper, salor-tailor, apache2, libapache2-mod-passenger 16 | Description: Innovative Point of Sale Solution serving the Hospitality Industry 17 | This package consists of a lean Ruby-on-Rails application, backed from a 18 | MySQL database. The actual Point of Sale interface is entirely controlled 19 | by offline Javascript and an offline database. This concept unites the 20 | advantages of networking between many handhelds in one store (or many 21 | stores of a restaurant/hotel chain) with an amazing responsiveness of the 22 | user interface (UI). 23 | -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/icons/help.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 6 | 12 | 13 | 14 | -------------------------------------------------------------------------------- /salor-hospitality/app/views/settlements/index.html.haml: -------------------------------------------------------------------------------- 1 | - cost_center_header_text = "(#{ CostCenter.model_name.human }: #{@selected_cost_center.name})" if @selected_cost_center 2 | %h2== #{ t 'activerecord.models.settlement.other' } #{ cost_center_header_text } 3 | 4 | = form_tag settlements_path, :method => :get do 5 | .limitby 6 | = label 'from', t('.start_date'), :class => 'right' 7 | = select_date(@from, :prefix => 'from', :order => [:year, :month, :day]) 8 | %br 9 | = label 'to', t('.end_date'), :class => 'right' 10 | = select_date(@to, :prefix => 'to', :order => [:year, :month, :day]) 11 | %br 12 | - if @cost_centers.any? 13 | = label 'cc', CostCenter.model_name.human, :class => 'right' 14 | %select{ :name => 'cost_center_id' } 15 | %option{ :value => '' }= t ('.all') 16 | - selected_id = @selected_cost_center ? @selected_cost_center.id.to_s : '' 17 | = options_from_collection_for_select(@cost_centers, :id, :name, selected_id) 18 | %br 19 | = label 'one_day_one_row', t('.one_day_one_row'), :class => 'right' 20 | = check_box_tag 'one_day_one_row', 1, params[:one_day_one_row] 21 | %hr 22 | = submit_tag t(:display) 23 | 24 | .clear 25 | 26 | - if params[:one_day_one_row] 27 | = render :partial => 'one_day_one_row' 28 | - else 29 | = render :partial => 'one_settlement_one_row' -------------------------------------------------------------------------------- /salor-hospitality/app/views/exception_notifier/exception_notification.html.erb: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | Exception 6 | 7 | 8 |
 9 | <%= @exception.class.to_s =~ /^[aeiou]/i ? 'An' : 'A' %> <%= @exception.class %> occurred in <%= @kontroller.controller_name %>#<%= @kontroller.action_name %>:
10 | 
11 | <%= raw @exception.message %>
12 | <%= raw @backtrace.first %>
13 | 
14 | <%
15 |     sections = @sections.map do |section|
16 |       begin
17 |         summary = render(section).strip
18 |         unless summary.blank?
19 |           title = render("title", :title => section).strip
20 |           "#{title}\n\n#{summary.gsub(/^/, "  ")}\n\n"
21 |         end
22 | 
23 |       rescue Exception => e
24 |         title = render("title", :title => section).strip
25 |         summary = ["ERROR: Failed to generate exception summary:", [e.class.to_s, e.message].join(": "), e.backtrace && e.backtrace.join("\n")].compact.join("\n\n")
26 | 
27 |         [title, summary.gsub(/^/, "  "), nil].join("\n\n")
28 |       end
29 |     end.join
30 |     sections = sections.force_encoding('UTF-8').encode('UTF-16', :invalid => :replace).encode('UTF-8') if sections.respond_to?(:force_encoding)
31 | %>
32 | 
33 | <%= raw sections %>
34 |   
35 | 36 | 37 | -------------------------------------------------------------------------------- /salor-hospitality/app/assets/javascripts/translations.js: -------------------------------------------------------------------------------- 1 | function render_translation_inputs(depth, ancestor_keys, tree, el) { 2 | $.each(tree, function(k,v) { 3 | if (typeof v == 'object') { 4 | var li = $(document.createElement('li')); 5 | li.html(k); 6 | el.append(li); 7 | var ul = $(document.createElement('ul')); 8 | el.append(ul); 9 | ancestor_keys.push(k); 10 | render_translation_inputs(depth+1, ancestor_keys, v, ul); 11 | ancestor_keys.pop(); 12 | } else { 13 | var li = $(document.createElement('li')); 14 | var keyspan = $(document.createElement('span')); 15 | keyspan.html(k); 16 | 17 | var valinput = $(document.createElement('input')); 18 | valinput.attr('ancestor_keys', ancestor_keys + ',' + k); 19 | valinput.val(v); 20 | valinput.on('change', function(){ 21 | submit_translation($(this)); 22 | }) 23 | valinput.on('click', function(){ 24 | $(this).css('background-color', 'white'); 25 | }) 26 | 27 | li.append(keyspan); 28 | li.append(valinput); 29 | el.append(li); 30 | } 31 | }) 32 | } 33 | 34 | function submit_translation(el) { 35 | el.css('background-color', '#99FF99'); 36 | $.ajax({ 37 | type: 'put', 38 | url: '/translations/set', 39 | data: {k:el.attr('ancestor_keys'), v:el.val(), f:translation_file} 40 | }) 41 | } -------------------------------------------------------------------------------- /salor-hospitality/app/assets/images/icons/statistic.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 6 | 8 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | -------------------------------------------------------------------------------- /salor-hospitality/app/helpers/vendors_helper.rb: -------------------------------------------------------------------------------- 1 | # coding: UTF-8 2 | 3 | # Copyright (c) 2012 Red (E) Tools Ltd. 4 | # 5 | # Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: 6 | # 7 | # The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. 8 | # 9 | # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 10 | 11 | module VendorsHelper 12 | 13 | def get_print_button_filename_array 14 | [ 15 | [t('.chef'), 'chef'], 16 | [t('.foods'), 'foods'], 17 | [t('.bar'), 'bar'], 18 | [t('.tables'), 'tables'] 19 | ] 20 | end 21 | end 22 | -------------------------------------------------------------------------------- /salor-hospitality/app/assets/javascripts/application.js: -------------------------------------------------------------------------------- 1 | // This is a manifest file that'll be compiled into including all the files listed below. 2 | // Add new JavaScript/Coffee code in separate files in this directory and they'll automatically 3 | // be included in the compiled file accessible from http://example.com/assets/application.js 4 | // It's not advisable to add code directly here, but if you do, it'll appear at the bottom of the 5 | // the compiled file. 6 | // 7 | //= require jquery 8 | //= require jquery.ui.all 9 | //= require jquery_ujs 10 | //= require colpick 11 | //= require ajax 12 | //= require articles 13 | //= require audio 14 | //= require autocompletable 15 | //= require categories 16 | //= require customers 17 | //= require dates 18 | //= require debug 19 | //= require dom-switching 20 | //= require draw 21 | //= require globals 22 | //= require hooks 23 | //= require intervals 24 | //= require item-notifications 25 | //= require items 26 | //= require jquery-data 27 | //= require json 28 | //= require keyboard 29 | //= require math 30 | //= require numbers 31 | //= require options 32 | //= require page 33 | //= require payment-methods 34 | //= require quantities 35 | //= require queue 36 | //= require resources 37 | //= require route 38 | //= require scrolling 39 | //= require split-item 40 | //= require tables 41 | //= require ui-helpers 42 | //= require ui-widgets 43 | //= require various 44 | -------------------------------------------------------------------------------- /salor-hospitality/app/views/orders/_order_form.html.haml: -------------------------------------------------------------------------------- 1 | %h3 2 | - if permit('order_notes') 3 | %span#order_info{ :onclick => '$("#note_for_order").slideDown()'}= t :just_order 4 | - else 5 | %span#order_info= t :just_order 6 | 7 | #note_for_order= render 'note' 8 | 9 | - unless @current_customer 10 | #tablesselect 11 | %h3= t :move_order_to_table 12 | %span.done{ :onclick => "close_table_div();" } 13 | #tablesselect_container 14 | 15 | - if workstation? and not @current_customer 16 | #usersselect 17 | %h3= t('roles.new.assign_order_to_user') 18 | %span.done{ :onclick => "$('#usersselect').slideUp();" } 19 | - @users.each do |u| 20 | %span.option{ :onclick => "submit_json.model.user_id = #{ u.id}; $('#usersselect').slideUp();" }== #{ u.login } 21 | 22 | #categories 23 | - @categories.existing.active.positioned.each do |category| 24 | .category{ :id => "category_#{ category.id }", :class => category.name.delete(' '), :style => "background-color: #{category.color}; background-image: url('#{category.icon_path}')", :onclick => "category_onmousedown(#{ category.id }, this)" } 25 | %div{ :class => "category_label" } 26 | %span= category.name 27 | 28 | #articles 29 | 30 | #items 31 | .ordersum_container 32 | - if workstation? 33 | %input#sku_input 34 | %span#order_sum 35 | 36 | %table#itemstable 37 | 38 | %h3 39 | %span#order_info_bottom -------------------------------------------------------------------------------- /debian/salor-hospitality.install: -------------------------------------------------------------------------------- 1 | salor-hospitality/app /usr/share/salor-hospitality/source 2 | salor-hospitality/config /usr/share/salor-hospitality/source 3 | salor-hospitality/lib /usr/share/salor-hospitality/source 4 | salor-hospitality/script /usr/share/salor-hospitality/source 5 | 6 | salor-hospitality/public/*.* /usr/share/salor-hospitality/source/public 7 | salor-hospitality/public/fonts /usr/share/salor-hospitality/source/public 8 | salor-hospitality/public/images /usr/share/salor-hospitality/source/public 9 | 10 | salor-hospitality/vendor/assets /usr/share/salor-hospitality/source/vendor 11 | salor-hospitality/vendor/cache /usr/share/salor-hospitality/source/vendor 12 | 13 | salor-hospitality/Gemfile /usr/share/salor-hospitality/source 14 | salor-hospitality/Gemfile.lock /usr/share/salor-hospitality/source 15 | salor-hospitality/Rakefile /usr/share/salor-hospitality/source 16 | salor-hospitality/config.ru /usr/share/salor-hospitality/source 17 | 18 | salor-hospitality/db/migrate /usr/share/salor-hospitality/source/db 19 | salor-hospitality/db/seeds.rb /usr/share/salor-hospitality/source/db 20 | 21 | debian/bin/salor-hospitality.desktop /usr/share/applications 22 | debian/bin/salor-hospitality /usr/bin 23 | salor-hospitality/app/assets/images/salor-hospitality-icon.svg /usr/share/icons/hicolor/scalable/apps --------------------------------------------------------------------------------