Uploaded image for project: 'Blesta Core'
  1. Blesta Core
  2. CORE-2568

Update service changes to show multiple coupon fields

    Details

    • Type: Improvement
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 4.2.1
    • Fix Version/s: 4.3.0-b1
    • Component/s: Staff Interface
    • Labels:
      None

      Description

      In the admin interface, when updating a service, there is a single Coupon Code field.

      This should be updated to:

      1. Add a new field called Current Coupon Code above the current Coupon Code field that is disabled.
        • This field just displays the coupon code of the current service, if any. It is unused
        • When processing a service change, the existing coupon should be used to process the service change removal
      2. The current Coupon Code field should be blank by default and it refers to the new coupon code to be added for the service change
        • The coupon entered into the Coupon Code field should only be applied to the new service change while the old coupon code is applied to the old service removal

        Issue Links

          Activity

          Hide
          jonathan Jonathan Reissmueller added a comment -

          Currently service changes assume that if a blank value is given for a new coupon, then the coupon is meant to stay the same. It seems that the intent and what really should be done is that if the not given at all then the coupon is meant to stay the same, but if it is empty it should be treated as the removal of the old coupon (This is the difference between an isset() and an empty()).

          Relevant code is currently in app/models/services_changes.php on lines 225-242 under ServiceChanges::getPresenter.

          Show
          jonathan Jonathan Reissmueller added a comment - Currently service changes assume that if a blank value is given for a new coupon, then the coupon is meant to stay the same. It seems that the intent and what really should be done is that if the not given at all then the coupon is meant to stay the same, but if it is empty it should be treated as the removal of the old coupon (This is the difference between an isset() and an empty()). Relevant code is currently in app/models/services_changes.php on lines 225-242 under ServiceChanges::getPresenter.
          Hide
          tyson Tyson Phillips (Inactive) added a comment -

          I think we are going to add an "Update Coupon" option as a service action, and the Upgrade/Downgrade section will allow you to set a new coupon that applies to the new package/term. The current service coupon will apply to the service you're upgrading from and a new coupon can be set to apply to the new package/term.

          Show
          tyson Tyson Phillips (Inactive) added a comment - I think we are going to add an "Update Coupon" option as a service action, and the Upgrade/Downgrade section will allow you to set a new coupon that applies to the new package/term. The current service coupon will apply to the service you're upgrading from and a new coupon can be set to apply to the new package/term.

            People

            • Assignee:
              jonathan Jonathan Reissmueller
              Reporter:
              tyson Tyson Phillips (Inactive)
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:
                Fix Release Date:
                15/Jun/18

                Time Tracking

                Estimated:
                Original Estimate - Not Specified
                Not Specified
                Remaining:
                Remaining Estimate - 0 minutes
                0m
                Logged:
                Time Spent - 4 hours, 10 minutes
                4h 10m

                  Agile