<commit_before>= render 'events/header'

.row
  = render 'event_orders/submenu'
  .span9
    .well
      ul.orders-stats
        li.orders-stat
          h2 #{stats_tickets_price(@orders)} 元
          p.muted 总金额
        li.orders-stat.last
          h2 #{stats_tickets_quantity (@orders)} 张
          p.muted 总票数

    = search_form_for @search, url: filter_event_orders_path(@event, status: params[:status]), html: { class: 'form-search' } do |f|
      label.margin-right for="q_items_ticket_id_eq" 包含门票
      = f.select :items_ticket_id_eq, @event.tickets.collect{|p| [ "#{p.name}", p.id ] }, {include_blank: true}, class: ['margin-right', 'span2']
      label.margin-right for="q_items_price_in_cents_gt_price" 门票单价>=
      = f.text_field :items_price_in_cents_gt_price, class: ['margin-right', 'span2'], placeholder: '（元）'
      = f.hidden_field :status_eq
      = f.submit class: 'btn', value: '查询'

    .orders-list ng-init=init_event_orders
      table.table.table-bordered ng-controller='EventOrdersCtrl'
        thead
          tr
            th width='100px' = t('views.my_orders.user')
            th = t('views.my_orders.items')
            th width='100px' = t('views.my_orders.price')
            th width='140px' = t('views.my_orders.trade_no')
            th width='100px' = t('views.my_orders.operation')
        tbody ng-repeat='order in orders'
          tr
            td
              a ng-href="/{{order.user.login}}" target="_blank"
                |{{order.user.login}}
            td
              ul.tickets-list
                li ng-repeat='item in order.items'
                  |{{item.name}}（{{item.price}}元） x {{item.quantity}}
            td
              |{{order.price}}
            td
              |{{order.number}}
            td.table-operate
              a href='javascript:void(0)' ng-click="show($index)" = t('buttons.orders.submit_refund')
              a ng-href="mailto:{{order.user.email}" 邮件
          tr
            td colspan=5 ng-show='order.submit_refund_form'
              form.form-horizontal
                .control-group
                  label.control-label for="price" 退款金额
                  .controls
                    input.input-large id='price' ng-model="price" type="text"
                .control-group
                  label.control-label for="reason" 退款原因
                  .controls
                    input.input-large id='reason' ng-model="reason" type="text"
                .form-actions
                  button.btn.btn-info ng-click='submit()' 提交
                  button.btn ng-click='show($index)' 取消<commit_msg>add tip to refund form.<commit_after>= render 'events/header'

.row
  = render 'event_orders/submenu'
  .span9
    .well
      ul.orders-stats
        li.orders-stat
          h2 #{stats_tickets_price(@orders)} 元
          p.muted 总金额
        li.orders-stat.last
          h2 #{stats_tickets_quantity (@orders)} 张
          p.muted 总票数

    = search_form_for @search, url: filter_event_orders_path(@event, status: params[:status]), html: { class: 'form-search' } do |f|
      label.margin-right for="q_items_ticket_id_eq" 包含门票
      = f.select :items_ticket_id_eq, @event.tickets.collect{|p| [ "#{p.name}", p.id ] }, {include_blank: true}, class: ['margin-right', 'span2']
      label.margin-right for="q_items_price_in_cents_gt_price" 门票单价>=
      = f.text_field :items_price_in_cents_gt_price, class: ['margin-right', 'span2'], placeholder: '（元）'
      = f.hidden_field :status_eq
      = f.submit class: 'btn', value: '查询'

    .orders-list ng-init=init_event_orders
      table.table.table-bordered ng-controller='EventOrdersCtrl'
        thead
          tr
            th width='100px' = t('views.my_orders.user')
            th = t('views.my_orders.items')
            th width='100px' = t('views.my_orders.price')
            th width='140px' = t('views.my_orders.trade_no')
            th width='100px' = t('views.my_orders.operation')
        tbody ng-repeat='order in orders'
          tr
            td
              a ng-href="/{{order.user.login}}" target="_blank"
                |{{order.user.login}}
            td
              ul.tickets-list
                li ng-repeat='item in order.items'
                  |{{item.name}}（{{item.price}}元） x {{item.quantity}}
            td
              |{{order.price}}
            td
              |{{order.number}}
            td.table-operate
              a href='javascript:void(0)' ng-click="show($index)" = t('buttons.orders.submit_refund')
              a ng-href="mailto:{{order.user.email}" 邮件
          tr
            td colspan=5 ng-show='order.submit_refund_form'
              form.form-horizontal
                .control-group
                  label.control-label for="price" 退款金额
                  .controls
                    input.input-large id='price' ng-model="price" type="text"
                .control-group
                  label.control-label for="reason" 退款原因
                  .controls
                    textarea.input-large id='reason' ng-model="reason" rows="3"
                    span.help-block 退款申请提交后将由 19屋 进行退款操作，您和下单用户都将收到邮件通知。
                .form-actions
                  button.btn.btn-info ng-click='submit()' 提交
                  button.btn ng-click='show($index)' 取消
{'fraction_non_alphanumeric': 0.13531979502751945, 'fraction_numerical': 0.007781362687416967, 'mean_word_length': 1.867247007616975, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 5, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '7043537', 'n_tokens_mistral': 1727, 'n_tokens_neox': 1702, 'n_words': 295}