fix: replace all occurrences of component_studly => vue_component

This commit is contained in:
Lance Edgar 2024-08-19 09:53:10 -05:00
parent b642c98d40
commit 1d56a4c0d0
28 changed files with 88 additions and 88 deletions

View file

@ -1697,7 +1697,7 @@ class Grid(WuttaGrid):
results['checked_rows'] = checked results['checked_rows'] = checked
# TODO: this seems a bit hacky, but is required for now to # TODO: this seems a bit hacky, but is required for now to
# initialize things on the client side... # initialize things on the client side...
var = '{}CurrentData'.format(self.component_studly) var = '{}CurrentData'.format(self.vue_component)
results['checked_rows_code'] = '[{}]'.format( results['checked_rows_code'] = '[{}]'.format(
', '.join(['{}[{}]'.format(var, i) for i in checked])) ', '.join(['{}[{}]'.format(var, i) for i in checked]))

View file

@ -83,7 +83,7 @@
% if master.results_executable and master.has_perm('execute_multiple'): % if master.results_executable and master.has_perm('execute_multiple'):
<script type="text/javascript"> <script type="text/javascript">
${execute_form.component_studly}.methods.submit = function() { ${execute_form.vue_component}.methods.submit = function() {
this.$refs.actualExecuteForm.submit() this.$refs.actualExecuteForm.submit()
} }
@ -123,9 +123,9 @@
% if master.results_executable and master.has_perm('execute_multiple'): % if master.results_executable and master.has_perm('execute_multiple'):
<script type="text/javascript"> <script type="text/javascript">
${execute_form.component_studly}.data = function() { return ${execute_form.component_studly}Data } ${execute_form.vue_component}.data = function() { return ${execute_form.vue_component}Data }
Vue.component('${execute_form.component}', ${execute_form.component_studly}) Vue.component('${execute_form.component}', ${execute_form.vue_component})
</script> </script>
% endif % endif

View file

@ -147,7 +147,7 @@
<script type="text/javascript"> <script type="text/javascript">
let ${form.component_studly} = { let ${form.vue_component} = {
template: '#${form.component}-template', template: '#${form.component}-template',
mixins: [SimpleRequestMixin], mixins: [SimpleRequestMixin],
@ -278,7 +278,7 @@
}, },
} }
let ${form.component_studly}Data = { let ${form.vue_component}Data = {
submitting: false, submitting: false,
productUPC: null, productUPC: null,

View file

@ -5,7 +5,7 @@
${parent.modify_this_page_vars()} ${parent.modify_this_page_vars()}
<script type="text/javascript"> <script type="text/javascript">
${form.component_studly}Data.taxesData = ${json.dumps(taxes_data)|n} ${form.vue_component}Data.taxesData = ${json.dumps(taxes_data)|n}
</script> </script>
</%def> </%def>

View file

@ -5,12 +5,12 @@
${parent.modify_this_page_vars()} ${parent.modify_this_page_vars()}
<script type="text/javascript"> <script type="text/javascript">
${form.component_studly}Data.parsers = ${json.dumps(parsers_data)|n} ${form.vue_component}Data.parsers = ${json.dumps(parsers_data)|n}
${form.component_studly}Data.vendorName = null ${form.vue_component}Data.vendorName = null
${form.component_studly}Data.vendorNameReplacement = null ${form.vue_component}Data.vendorNameReplacement = null
${form.component_studly}.watch.field_model_parser_key = function(val) { ${form.vue_component}.watch.field_model_parser_key = function(val) {
let parser = this.parsers[val] let parser = this.parsers[val]
if (parser.vendor_uuid) { if (parser.vendor_uuid) {
if (this.field_model_vendor_uuid != parser.vendor_uuid) { if (this.field_model_vendor_uuid != parser.vendor_uuid) {
@ -24,11 +24,11 @@
} }
} }
${form.component_studly}.methods.vendorLabelChanging = function(label) { ${form.vue_component}.methods.vendorLabelChanging = function(label) {
this.vendorNameReplacement = label this.vendorNameReplacement = label
} }
${form.component_studly}.methods.vendorChanged = function(uuid) { ${form.vue_component}.methods.vendorChanged = function(uuid) {
if (uuid) { if (uuid) {
this.vendorName = this.vendorNameReplacement this.vendorName = this.vendorNameReplacement
this.vendorNameReplacement = null this.vendorNameReplacement = null

View file

@ -285,7 +285,7 @@
} }
% if not batch.executed and master.has_perm('edit'): % if not batch.executed and master.has_perm('edit'):
${form.component_studly}Data.togglingBatchComplete = false ${form.vue_component}Data.togglingBatchComplete = false
% endif % endif
% if master.has_worksheet_file and master.allow_worksheet(batch) and master.has_perm('worksheet'): % if master.has_worksheet_file and master.allow_worksheet(batch) and master.has_perm('worksheet'):
@ -306,7 +306,7 @@
form.submit() form.submit()
} }
${upload_worksheet_form.component_studly}.methods.submit = function() { ${upload_worksheet_form.vue_component}.methods.submit = function() {
this.$refs.actualUploadForm.submit() this.$refs.actualUploadForm.submit()
} }
@ -321,7 +321,7 @@
this.$refs.executeBatchForm.submit() this.$refs.executeBatchForm.submit()
} }
${execute_form.component_studly}.methods.submit = function() { ${execute_form.vue_component}.methods.submit = function() {
this.$refs.actualExecuteForm.submit() this.$refs.actualExecuteForm.submit()
} }
@ -329,9 +329,9 @@
% if master.rows_bulk_deletable and not batch.executed and master.has_perm('delete_rows'): % if master.rows_bulk_deletable and not batch.executed and master.has_perm('delete_rows'):
${rows_grid.component_studly}Data.deleteResultsShowDialog = false ${rows_grid.vue_component}Data.deleteResultsShowDialog = false
${rows_grid.component_studly}.methods.deleteResultsInit = function() { ${rows_grid.vue_component}.methods.deleteResultsInit = function() {
this.deleteResultsShowDialog = true this.deleteResultsShowDialog = true
} }
@ -346,8 +346,8 @@
<script type="text/javascript"> <script type="text/javascript">
## UploadForm ## UploadForm
${upload_worksheet_form.component_studly}.data = function() { return ${upload_worksheet_form.component_studly}Data } ${upload_worksheet_form.vue_component}.data = function() { return ${upload_worksheet_form.vue_component}Data }
Vue.component('${upload_worksheet_form.component}', ${upload_worksheet_form.component_studly}) Vue.component('${upload_worksheet_form.component}', ${upload_worksheet_form.vue_component})
</script> </script>
% endif % endif
@ -356,8 +356,8 @@
<script type="text/javascript"> <script type="text/javascript">
## ExecuteForm ## ExecuteForm
${execute_form.component_studly}.data = function() { return ${execute_form.component_studly}Data } ${execute_form.vue_component}.data = function() { return ${execute_form.vue_component}Data }
Vue.component('${execute_form.component}', ${execute_form.component_studly}) Vue.component('${execute_form.component}', ${execute_form.vue_component})
</script> </script>
% endif % endif

View file

@ -21,10 +21,10 @@
<script type="text/javascript"> <script type="text/javascript">
% if expose_shoppers: % if expose_shoppers:
${form.component_studly}Data.shoppers = ${json.dumps(shoppers_data)|n} ${form.vue_component}Data.shoppers = ${json.dumps(shoppers_data)|n}
% endif % endif
% if expose_people: % if expose_people:
${form.component_studly}Data.peopleData = ${json.dumps(people_data)|n} ${form.vue_component}Data.peopleData = ${json.dumps(people_data)|n}
% endif % endif
ThisPage.methods.detachPerson = function(url) { ThisPage.methods.detachPerson = function(url) {

View file

@ -295,7 +295,7 @@
${parent.modify_this_page_vars()} ${parent.modify_this_page_vars()}
<script type="text/javascript"> <script type="text/javascript">
${form.component_studly}Data.eventsData = ${json.dumps(events_data)|n} ${form.vue_component}Data.eventsData = ${json.dumps(events_data)|n}
% if master.has_perm('confirm_price'): % if master.has_perm('confirm_price'):
@ -392,9 +392,9 @@
this.$refs.changeStatusForm.submit() this.$refs.changeStatusForm.submit()
} }
${form.component_studly}Data.changeFlaggedSubmitting = false ${form.vue_component}Data.changeFlaggedSubmitting = false
${form.component_studly}.methods.changeFlaggedSubmit = function() { ${form.vue_component}.methods.changeFlaggedSubmit = function() {
this.changeFlaggedSubmitting = true this.changeFlaggedSubmitting = true
} }

View file

@ -5,7 +5,7 @@
${parent.modify_this_page_vars()} ${parent.modify_this_page_vars()}
<script type="text/javascript"> <script type="text/javascript">
${form.component_studly}Data.employeesData = ${json.dumps(employees_data)|n} ${form.vue_component}Data.employeesData = ${json.dumps(employees_data)|n}
</script> </script>
</%def> </%def>

View file

@ -67,21 +67,21 @@
${parent.modify_this_page_vars()} ${parent.modify_this_page_vars()}
<script type="text/javascript"> <script type="text/javascript">
${form.component_studly}Data.submittingRun = false ${form.vue_component}Data.submittingRun = false
${form.component_studly}Data.submittingExplain = false ${form.vue_component}Data.submittingExplain = false
${form.component_studly}Data.runJob = false ${form.vue_component}Data.runJob = false
${form.component_studly}.methods.submitRun = function() { ${form.vue_component}.methods.submitRun = function() {
this.submittingRun = true this.submittingRun = true
this.runJob = true this.runJob = true
this.$nextTick(() => { this.$nextTick(() => {
this.$refs.${form.component_studly}.submit() this.$refs.${form.vue_component}.submit()
}) })
} }
${form.component_studly}.methods.submitExplain = function() { ${form.vue_component}.methods.submitExplain = function() {
this.submittingExplain = true this.submittingExplain = true
this.$refs.${form.component_studly}.submit() this.$refs.${form.vue_component}.submit()
} }
</script> </script>

View file

@ -60,19 +60,19 @@
<%def name="modify_this_page_vars()"> <%def name="modify_this_page_vars()">
<script type="text/javascript"> <script type="text/javascript">
${form.component_studly}Data.usernameInput = null ${form.vue_component}Data.usernameInput = null
${form.component_studly}.mounted = function() { ${form.vue_component}.mounted = function() {
this.$refs.username.focus() this.$refs.username.focus()
this.usernameInput = this.$refs.username.$el.querySelector('input') this.usernameInput = this.$refs.username.$el.querySelector('input')
this.usernameInput.addEventListener('keydown', this.usernameKeydown) this.usernameInput.addEventListener('keydown', this.usernameKeydown)
} }
${form.component_studly}.beforeDestroy = function() { ${form.vue_component}.beforeDestroy = function() {
this.usernameInput.removeEventListener('keydown', this.usernameKeydown) this.usernameInput.removeEventListener('keydown', this.usernameKeydown)
} }
${form.component_studly}.methods.usernameKeydown = function(event) { ${form.vue_component}.methods.usernameKeydown = function(event) {
if (event.which == 13) { if (event.which == 13) {
event.preventDefault() event.preventDefault()
this.$refs.password.focus() this.$refs.password.focus()

View file

@ -8,7 +8,7 @@
## declare extra data needed by form ## declare extra data needed by form
% if form is not Undefined and getattr(form, 'json_data', None): % if form is not Undefined and getattr(form, 'json_data', None):
% for key, value in form.json_data.items(): % for key, value in form.json_data.items():
${form.component_studly}Data.${key} = ${json.dumps(value)|n} ${form.vue_component}Data.${key} = ${json.dumps(value)|n}
% endfor % endfor
% endif % endif

View file

@ -67,31 +67,31 @@
% if getattr(master, 'mergeable', False) and master.has_perm('request_merge'): % if getattr(master, 'mergeable', False) and master.has_perm('request_merge'):
${grid.component_studly}Data.mergeRequestShowDialog = false ${grid.vue_component}Data.mergeRequestShowDialog = false
${grid.component_studly}Data.mergeRequestRows = [] ${grid.vue_component}Data.mergeRequestRows = []
${grid.component_studly}Data.mergeRequestSubmitText = "Submit Merge Request" ${grid.vue_component}Data.mergeRequestSubmitText = "Submit Merge Request"
${grid.component_studly}Data.mergeRequestSubmitting = false ${grid.vue_component}Data.mergeRequestSubmitting = false
${grid.component_studly}.computed.mergeRequestRemovingUUID = function() { ${grid.vue_component}.computed.mergeRequestRemovingUUID = function() {
if (this.mergeRequestRows.length) { if (this.mergeRequestRows.length) {
return this.mergeRequestRows[0].uuid return this.mergeRequestRows[0].uuid
} }
return null return null
} }
${grid.component_studly}.computed.mergeRequestKeepingUUID = function() { ${grid.vue_component}.computed.mergeRequestKeepingUUID = function() {
if (this.mergeRequestRows.length) { if (this.mergeRequestRows.length) {
return this.mergeRequestRows[1].uuid return this.mergeRequestRows[1].uuid
} }
return null return null
} }
${grid.component_studly}.methods.showMergeRequest = function() { ${grid.vue_component}.methods.showMergeRequest = function() {
this.mergeRequestRows = this.checkedRows this.mergeRequestRows = this.checkedRows
this.mergeRequestShowDialog = true this.mergeRequestShowDialog = true
} }
${grid.component_studly}.methods.submitMergeRequest = function() { ${grid.vue_component}.methods.submitMergeRequest = function() {
this.mergeRequestSubmitting = true this.mergeRequestSubmitting = true
this.mergeRequestSubmitText = "Working, please wait..." this.mergeRequestSubmitText = "Working, please wait..."
} }

View file

@ -67,11 +67,11 @@
% if master.has_perm('replace'): % if master.has_perm('replace'):
<script type="text/javascript"> <script type="text/javascript">
${form.component_studly}Data.showUploadForm = false ${form.vue_component}Data.showUploadForm = false
${form.component_studly}Data.uploadFile = null ${form.vue_component}Data.uploadFile = null
${form.component_studly}Data.uploadSubmitting = false ${form.vue_component}Data.uploadSubmitting = false
</script> </script>
% endif % endif

View file

@ -22,7 +22,7 @@
</%def> </%def>
<%def name="render_form_innards()"> <%def name="render_form_innards()">
${h.form(request.current_route_url(), **{'@submit': 'submit{}'.format(form.component_studly)})} ${h.form(request.current_route_url(), **{'@submit': 'submit{}'.format(form.vue_component)})}
${h.csrf_token(request)} ${h.csrf_token(request)}
<section> <section>
@ -43,8 +43,8 @@
<div class="buttons"> <div class="buttons">
<b-button type="is-primary" <b-button type="is-primary"
native-type="submit" native-type="submit"
:disabled="${form.component_studly}Submitting"> :disabled="${form.vue_component}Submitting">
{{ ${form.component_studly}ButtonText }} {{ ${form.vue_component}ButtonText }}
</b-button> </b-button>
<b-button tag="a" href="${url('products')}"> <b-button tag="a" href="${url('products')}">
Cancel Cancel
@ -66,21 +66,21 @@
## TODO: ugh, an awful lot of duplicated code here (from /forms/deform.mako) ## TODO: ugh, an awful lot of duplicated code here (from /forms/deform.mako)
let ${form.component_studly} = { let ${form.vue_component} = {
template: '#${form.component}-template', template: '#${form.component}-template',
methods: { methods: {
## TODO: deprecate / remove the latter option here ## TODO: deprecate / remove the latter option here
% if form.auto_disable_save or form.auto_disable: % if form.auto_disable_save or form.auto_disable:
submit${form.component_studly}() { submit${form.vue_component}() {
this.${form.component_studly}Submitting = true this.${form.vue_component}Submitting = true
this.${form.component_studly}ButtonText = "Working, please wait..." this.${form.vue_component}ButtonText = "Working, please wait..."
} }
% endif % endif
} }
} }
let ${form.component_studly}Data = { let ${form.vue_component}Data = {
## TODO: ugh, this seems pretty hacky. need to declare some data models ## TODO: ugh, this seems pretty hacky. need to declare some data models
## for various field components to bind to... ## for various field components to bind to...
@ -95,8 +95,8 @@
## TODO: deprecate / remove the latter option here ## TODO: deprecate / remove the latter option here
% if form.auto_disable_save or form.auto_disable: % if form.auto_disable_save or form.auto_disable:
${form.component_studly}Submitting: false, ${form.vue_component}Submitting: false,
${form.component_studly}ButtonText: ${json.dumps(getattr(form, 'submit_label', getattr(form, 'save_label', "Submit")))|n}, ${form.vue_component}ButtonText: ${json.dumps(getattr(form, 'submit_label', getattr(form, 'save_label', "Submit")))|n},
% endif % endif
## TODO: more hackiness, this is for the sake of batch params ## TODO: more hackiness, this is for the sake of batch params

View file

@ -41,11 +41,11 @@
% if label_profiles and master.has_perm('print_labels'): % if label_profiles and master.has_perm('print_labels'):
<script type="text/javascript"> <script type="text/javascript">
${grid.component_studly}Data.quickLabelProfile = ${json.dumps(label_profiles[0].uuid)|n} ${grid.vue_component}Data.quickLabelProfile = ${json.dumps(label_profiles[0].uuid)|n}
${grid.component_studly}Data.quickLabelQuantity = 1 ${grid.vue_component}Data.quickLabelQuantity = 1
${grid.component_studly}Data.quickLabelSpeedbumpThreshold = ${json.dumps(quick_label_speedbump_threshold)|n} ${grid.vue_component}Data.quickLabelSpeedbumpThreshold = ${json.dumps(quick_label_speedbump_threshold)|n}
${grid.component_studly}.methods.quickLabelPrint = function(row) { ${grid.vue_component}.methods.quickLabelPrint = function(row) {
let quantity = parseInt(this.quickLabelQuantity) let quantity = parseInt(this.quickLabelQuantity)
if (isNaN(quantity)) { if (isNaN(quantity)) {

View file

@ -63,17 +63,17 @@
${parent.modify_this_page_vars()} ${parent.modify_this_page_vars()}
<script type="text/javascript"> <script type="text/javascript">
${grid.component_studly}Data.changeStatusShowDialog = false ${grid.vue_component}Data.changeStatusShowDialog = false
${grid.component_studly}Data.changeStatusOptions = ${json.dumps(status_options)|n} ${grid.vue_component}Data.changeStatusOptions = ${json.dumps(status_options)|n}
${grid.component_studly}Data.changeStatusValue = null ${grid.vue_component}Data.changeStatusValue = null
${grid.component_studly}Data.changeStatusSubmitting = false ${grid.vue_component}Data.changeStatusSubmitting = false
${grid.component_studly}.methods.changeStatusInit = function() { ${grid.vue_component}.methods.changeStatusInit = function() {
this.changeStatusValue = null this.changeStatusValue = null
this.changeStatusShowDialog = true this.changeStatusShowDialog = true
} }
${grid.component_studly}.methods.changeStatusSubmit = function() { ${grid.vue_component}.methods.changeStatusSubmit = function() {
this.changeStatusSubmitting = true this.changeStatusSubmitting = true
this.$refs.changeStatusForm.submit() this.$refs.changeStatusForm.submit()
} }

View file

@ -318,13 +318,13 @@
% if allow_edit_catalog_unit_cost: % if allow_edit_catalog_unit_cost:
${rows_grid.component_studly}.methods.catalogUnitCostClicked = function(row) { ${rows_grid.vue_component}.methods.catalogUnitCostClicked = function(row) {
// start edit for clicked cell // start edit for clicked cell
this.$refs['catalogUnitCost_' + row.uuid].startEdit() this.$refs['catalogUnitCost_' + row.uuid].startEdit()
} }
${rows_grid.component_studly}.methods.catalogCostConfirmed = function(amount, index) { ${rows_grid.vue_component}.methods.catalogCostConfirmed = function(amount, index) {
// update display to indicate cost was confirmed // update display to indicate cost was confirmed
this.addRowClass(index, 'catalog_cost_confirmed') this.addRowClass(index, 'catalog_cost_confirmed')
@ -353,13 +353,13 @@
% if allow_edit_invoice_unit_cost: % if allow_edit_invoice_unit_cost:
${rows_grid.component_studly}.methods.invoiceUnitCostClicked = function(row) { ${rows_grid.vue_component}.methods.invoiceUnitCostClicked = function(row) {
// start edit for clicked cell // start edit for clicked cell
this.$refs['invoiceUnitCost_' + row.uuid].startEdit() this.$refs['invoiceUnitCost_' + row.uuid].startEdit()
} }
${rows_grid.component_studly}.methods.invoiceCostConfirmed = function(amount, index) { ${rows_grid.vue_component}.methods.invoiceCostConfirmed = function(amount, index) {
// update display to indicate cost was confirmed // update display to indicate cost was confirmed
this.addRowClass(index, 'invoice_cost_confirmed') this.addRowClass(index, 'invoice_cost_confirmed')

View file

@ -6,7 +6,7 @@
<script type="text/javascript"> <script type="text/javascript">
% if params_data is not Undefined: % if params_data is not Undefined:
${form.component_studly}Data.paramsData = ${json.dumps(params_data)|n} ${form.vue_component}Data.paramsData = ${json.dumps(params_data)|n}
% endif % endif
</script> </script>

View file

@ -28,7 +28,7 @@
<script type="text/javascript"> <script type="text/javascript">
% if params_data is not Undefined: % if params_data is not Undefined:
${form.component_studly}Data.paramsData = ${json.dumps(params_data)|n} ${form.vue_component}Data.paramsData = ${json.dumps(params_data)|n}
% endif % endif
</script> </script>

View file

@ -67,7 +67,7 @@
<script type="text/javascript"> <script type="text/javascript">
% if weekdays_data is not Undefined: % if weekdays_data is not Undefined:
${form.component_studly}Data.weekdaysData = ${json.dumps(weekdays_data)|n} ${form.vue_component}Data.weekdaysData = ${json.dumps(weekdays_data)|n}
% endif % endif
ThisPageData.runReportShowDialog = false ThisPageData.runReportShowDialog = false

View file

@ -11,7 +11,7 @@
<script type="text/javascript"> <script type="text/javascript">
% if users_data is not Undefined: % if users_data is not Undefined:
${form.component_studly}Data.usersData = ${json.dumps(users_data)|n} ${form.vue_component}Data.usersData = ${json.dumps(users_data)|n}
% endif % endif
ThisPage.methods.detachPerson = function(url) { ThisPage.methods.detachPerson = function(url) {

View file

@ -26,9 +26,9 @@
this.$refs.grid.showEmails = this.showEmails this.$refs.grid.showEmails = this.showEmails
} }
${grid.component_studly}Data.showEmails = 'available' ${grid.vue_component}Data.showEmails = 'available'
${grid.component_studly}.computed.visibleData = function() { ${grid.vue_component}.computed.visibleData = function() {
if (this.showEmails == 'available') { if (this.showEmails == 'available') {
return this.data.filter(email => email.hidden == 'No') return this.data.filter(email => email.hidden == 'No')
@ -41,11 +41,11 @@
return this.data return this.data
} }
${grid.component_studly}.methods.renderLabelToggleHidden = function(row) { ${grid.vue_component}.methods.renderLabelToggleHidden = function(row) {
return row.hidden == 'Yes' ? "Un-hide" : "Hide" return row.hidden == 'Yes' ? "Un-hide" : "Hide"
} }
${grid.component_studly}.methods.toggleHidden = function(row) { ${grid.vue_component}.methods.toggleHidden = function(row) {
let url = '${url('{}.toggle_hidden'.format(route_prefix))}' let url = '${url('{}.toggle_hidden'.format(route_prefix))}'
let params = { let params = {
key: row.key, key: row.key,

View file

@ -12,7 +12,7 @@
${parent.modify_this_page_vars()} ${parent.modify_this_page_vars()}
<script type="text/javascript"> <script type="text/javascript">
${form.component_studly}Data.probesData = ${json.dumps(probes_data)|n} ${form.vue_component}Data.probesData = ${json.dumps(probes_data)|n}
</script> </script>
</%def> </%def>

View file

@ -26,7 +26,7 @@
${parent.modify_this_page_vars()} ${parent.modify_this_page_vars()}
<script type="text/javascript"> <script type="text/javascript">
${form.component_studly}Data.probesData = ${json.dumps(probes_data)|n} ${form.vue_component}Data.probesData = ${json.dumps(probes_data)|n}
</script> </script>
</%def> </%def>

View file

@ -6,7 +6,7 @@
<script type="text/javascript"> <script type="text/javascript">
% if custorder_xref_markers_data is not Undefined: % if custorder_xref_markers_data is not Undefined:
${form.component_studly}Data.custorderXrefMarkersData = ${json.dumps(custorder_xref_markers_data)|n} ${form.vue_component}Data.custorderXrefMarkersData = ${json.dumps(custorder_xref_markers_data)|n}
% endif % endif
</script> </script>

View file

@ -6,7 +6,7 @@
<script type="text/javascript"> <script type="text/javascript">
% if discounts_data is not Undefined: % if discounts_data is not Undefined:
${form.component_studly}Data.discountsData = ${json.dumps(discounts_data)|n} ${form.vue_component}Data.discountsData = ${json.dumps(discounts_data)|n}
% endif % endif
</script> </script>

View file

@ -81,7 +81,7 @@
% if master.has_perm('manage_api_tokens'): % if master.has_perm('manage_api_tokens'):
<script type="text/javascript"> <script type="text/javascript">
${form.component_studly}.props.apiTokens = null ${form.vue_component}.props.apiTokens = null
ThisPageData.apiTokens = ${json.dumps(api_tokens_data)|n} ThisPageData.apiTokens = ${json.dumps(api_tokens_data)|n}