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

Implemented: logic to create search preference and schedule a service (#29bdb9f) #40

Merged
merged 22 commits into from
May 5, 2022

Conversation

ymaheshwari1
Copy link
Contributor

No description provided.

…ference and stringify the query when storing it in preference, also passed viewSize when fetching the data for jobs(#29bdb9f)

<ion-item>
<ion-label>{{ $t("Rule name") }}</ion-label>
<ion-input placeholder="rule name" v-model="jobName"/>
Copy link
Contributor

Choose a reason for hiding this comment

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

Internationalise placeholder

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Added placeholder in internationalization file

closeModal() {
modalController.dismiss({ dismissed: true });
},
async createSearchPreference() {
Copy link
Contributor

Choose a reason for hiding this comment

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

Suggested change
async createSearchPreference() {
async saveThresholdRule() {

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Improved method name

},
"entityName": "ShopifyConfig",
"noConditionFind": "Y",
"fieldList": ["shopifyConfigId", "productStoreId"]
Copy link
Contributor

Choose a reason for hiding this comment

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

Pass viewSize

Copy link
Contributor Author

Choose a reason for hiding this comment

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

For now added viewSize as 1.

},
methods: {
updateInclusionQuery(value: string, type: string) {
this.included[type].includes(value) ? this.included[type].splice(this.included[type].indexOf(value), 1) : this.included[type].push(value)
Copy link
Contributor

Choose a reason for hiding this comment

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

Assign this.included[type] to a variable and then use

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Done Sir

// to remove that value from the query filter
this.query.json['filter'] = ["docType: PRODUCT"]

this.included['tags'].length > 0 && this.query.json['filter'].push(`tags: (${this.included['tags'].join(' OR ')})`)
Copy link
Contributor

Choose a reason for hiding this comment

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

We could iterate using reduce and prepare it dynamically

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Sir, used reduce to prepare the query.

@adityasharma7 adityasharma7 changed the title Implemented: logic to create search preference and schedule a service Implemented: logic to create search preference and schedule a service (#29bdb9f) May 5, 2022
@adityasharma7 adityasharma7 merged commit ac90608 into hotwax:main May 5, 2022
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.

2 participants