src/Bidcoz/Bundle/FrontendBundle/Resources/views/Sponsorship/new.html.twig line 1

Open in your IDE?
  1. {% extends '@BidcozFrontend/campaign.html.twig' %}
  2. {% block beforeContent %}
  3.     {{ parent() }}
  4.     <h1>Become a Sponsor</h1>
  5. {% endblock %}
  6. {% block content %}
  7.     <div class="panel sponsor-content h-100">
  8.         <div class="panel-body">
  9. {#            {% if not is_logged_in() %}#}
  10. {#                <div class="select-type-default center text-center">#}
  11. {#                    <div class="d-flex justify-content-center">#}
  12. {#                        <img src="{{ asset('img/components/sponsorships.png') }}" height="76" />#}
  13. {#                    </div>#}
  14. {#                    <h6 class="lead mt-3">#}
  15. {#                        Sign In or Create an Account to become a sponsor.<br>#}
  16. {#                        <a href="{{ path('campaign_login_user', campaignParams)}}" data-toggle="modal" data-target="#loginModal" class="btn btn-success trigger-login mt-3 w-25">Sign In or Create Account</a>#}
  17. {#                    </h6>#}
  18. {#                </div>#}
  19. {#            {% else %}#}
  20.             <div class="sponsor-ad-info">
  21.                 <h4 class="mt-1 mb-4">Choose your Level</h4>
  22.                 <p>
  23.                     Sponsor Spots appear in rotation across the bottom of each page based on Level.
  24.                     The "All Sponsors" page will contain each Spot ordered from highest level to lowest.
  25.                     When the Sponsor Spot is clicked, the viewer will be directed to your website URL.
  26.                 </p>
  27.                 <p>
  28.                     After payment is received, a representative will contact you to discuss your Sponsor Spot image.
  29.                     All submissions are subject to approval before publishing.
  30.                     <strong><a href="{{ path('campaign_contact', campaignParams) }}" class="link">Contact Us</a></strong>
  31.                     if you have any questions or need assistance.
  32.                 </p>
  33.                 <p>
  34.                     <strong>This is a Sponsor Spot purchase only.</strong>
  35.                 </p>
  36.             </div>
  37.             <div class="sponsor-ad-form">
  38.                     <h6 class="mt-4">Sponsor Level</h6>
  39.                     <p id="selected-level" data-slot="">Please choose a Level</p>
  40.                     <div class="sponsor-levels row">
  41.                         {% for level in levels|reverse %}
  42.                             <div class="col-12 col-md-6 col-xl-3">
  43.                                 <div class="panel sponsor-level">
  44.                                     <div class="panel-body py-4" style="border: 0.125rem solid #dadada;">
  45.                                         {% if level.image and level.image.id %}
  46.                                         {% set imgUrl = vich_uploader_asset(level.image, 'file') %}
  47.                                             <img src="{{ imgUrl }}" alt="{{ level.name }}" class="img-fluid w-100 mb-3" style="max-height: 150px; max-width: 100%; object-fit: contain;">
  48.                                         {% endif %}
  49.                                         <h6>{{ level.name }}</h6>
  50.                                         <p class="price text-secondary">
  51.                                             <strong>{{ level.price|money }}</strong>
  52.                                         </p>
  53.                                         <p>
  54.                                             {{ level.description|raw }}
  55.                                             {% if level.slots == 4 %}
  56.                                                 <br />8x display rate
  57.                                             {% elseif level.slots == 3 %}
  58.                                                 <br />4x display rate
  59.                                             {% elseif level.slots == 2 %}
  60.                                                 <br />2x display rate
  61.                                             {% else %}
  62.                                                 <br />Base display rate
  63.                                             {% endif %}
  64.                                         </p>
  65.                                         {% if level is sponsorship_soldout %}
  66.                                             <a href="#" class="btn btn-danger btn-outline w-100 mt-2 disabled" disabled>Sold Out</a>
  67.                                         {% else %}
  68.                                             <a id='{{level.id}}' data-name="{{ level.name }}" data-slots="{{ level.slots }}" href="#" class="sponsor-select btn btn-secondary w-100 mt-2">Select</a>
  69.                                         {% endif %}
  70.                                     </div>
  71.                                 </div>
  72.                             </div>
  73.                         {% endfor %}
  74.                     </div>
  75.                     <div class="row">
  76.                         <div class="col-12 col-lg-6">
  77.                             <h6 class="mt-4">Upload Image</h6>
  78.                             <p>Image should be <strong>square</strong> and at least <strong>600 x 600</strong> pixels.</p>
  79.                             <table class="table mt-3" id="images-table"></table>
  80.                             <form id="image-upload-form" action="{{ path('frontend_media_upload', campaignParams) }}" method="post" enctype="multipart/form-data" class="media-upload-file media-form mb-4">
  81.                                 <div class="form-group">
  82.                                     <input type="file" name="image[file][file]" />
  83.                                     <button id="img-upload-btn" class="btn btn-primary btn-sm w-25 mt-4 mx-0 d-flex align-items-center" style="line-height: 1.5rem; min-width: 200px;">
  84.                                         Upload<span class="d-none" id="upload_processing" style="line-height: 1.5rem;">ing <img src='/img/ajax-loader.gif' alt="loading" height="20" style="vertical-align:middle; display: inline-block;" /> </span>
  85.                                     </button>
  86.                                 </div>
  87.                             </form>
  88.                         </div>
  89.                         <div class="col-12 col-lg-6">
  90.                             <h6 class="mt-4">Link to your Website</h6>
  91.                             <p>Sponsor Spot images, when clicked will link to the web address of your choice.</p>
  92.                             <form action="" id="main-form" method="post">
  93.                                 {% include '@BidcozFrontend/Sponsorship/form.html.twig' %}
  94.                             </form>
  95.                         </div>
  96.                     </div>
  97.                     <button class="button-main-form btn btn-success w-25 mt-4" onclick="document.getElementById('main-form').submit()" disabled>Add To Cart</button>
  98.                 </div>
  99. {#            {% endif %}#}
  100.         </div>
  101.     </div>
  102. {% endblock %}
  103. {% block javascripts %}
  104.     {{ parent() }}
  105.     <script type='javascript'>
  106.         //$('#sponsorship_level').parent('div').addClass('d-none');
  107.         //$('form button').attr('disabled', 'disabled');
  108.     </script>
  109. {% endblock %}