Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Rename variable and function names and add functional tests for booking workflows #131

Open
wants to merge 10 commits into
base: main
Choose a base branch
from

Conversation

vidya-ram
Copy link
Member

  1. Rename variable and function names to follow camel case convention.
  2. Change boxoffice widget variable.
  3. Add currency format function to client side.
  4. Add functional tests for booking workflows using Casperjs

@@ -21,22 +21,22 @@ export const Util = {
}
}

export const fetch = function(config){
export const Fetch = function(config){
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why is this capitalized? Capitals are usually reserved for constructors.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Or for container objects.

return $.ajax({
url: config.url,
type: 'POST',
dataType: 'json'
});
}

export const scrollToElement = function(element, speed=500) {
export const ScrollToElement = function(element, speed=500) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same as above. This should be scrollToElement.

{{#details:k,v}}
{{#if k !== 'logo'}}
<p class="section-title">{{k}}</p>
<div class="section-content">{{{details[k]}}}</div>
<p class="section-title">{{ k }}</p>
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What is k?

<p><span class="italic-title">Final amount:</span> {{ currency }}{{ final_amount }}</p>
<p><span class="italic-title">Base amount:</span> {{ formatCurrency(base_amount) }}</p>
<p><span class="italic-title">Discounted amount:</span> {{ formatCurrency(discounted_amount) }}</p>
<p><span class="italic-title">Final amount:</span> {{ formatCurrency(final_amount) }}</p>
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Shouldn't base_amount, discounted_amount and final_amount also be in camelCase?

@CLAassistant
Copy link

CLAassistant commented May 16, 2022

CLA assistant check
All committers have signed the CLA.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants