fix
This commit is contained in:
@@ -204,6 +204,8 @@ module.exports = {
|
||||
},
|
||||
isMacrosPresent: function(){
|
||||
if(this.config.macros!=undefined){
|
||||
console.log("isMacrosPresent",this.config.macros!=undefined);
|
||||
console.log(this.config.macros.length!=0);
|
||||
return this.config.macros.length!=0;
|
||||
}
|
||||
return false;
|
||||
|
||||
@@ -8,7 +8,6 @@ module.exports = {
|
||||
|
||||
data: function (){
|
||||
return {
|
||||
no_of_macros : 0,
|
||||
toolpath_progress: 0,
|
||||
}
|
||||
},
|
||||
@@ -38,9 +37,6 @@ module.exports = {
|
||||
utils.clickFileInput("gcode-file-input");
|
||||
console.log("utils done");
|
||||
},
|
||||
getMacrosList : function (){
|
||||
return no_of_macros;
|
||||
},
|
||||
load: function() {
|
||||
const file_time = this.state.selected_time;
|
||||
console.log('file_time',this.state.selected_time);
|
||||
@@ -67,6 +63,8 @@ module.exports = {
|
||||
name:macrosName,
|
||||
color:macrosColor
|
||||
})
|
||||
console.log("Successfully saved");
|
||||
console.lof(this.config.macros);
|
||||
},
|
||||
}
|
||||
}
|
||||
@@ -207,8 +207,9 @@ script#control-view-template(type="text/x-template")
|
||||
label {{(progress || 0) | percent}}
|
||||
.bar(:style="'width:' + (progress || 0) * 100 + '%'")
|
||||
|
||||
.macros-buttons(v-if="this.config.macros!=undefined")
|
||||
<p>there is a macro
|
||||
.macros-div
|
||||
.macros-buttons(v-if="isMacrosPresent")
|
||||
<p> there is a macro
|
||||
|
||||
.tabs
|
||||
|
||||
|
||||
@@ -14,6 +14,6 @@ script#macros-template(type="text/x-template")
|
||||
v-model="state.selected", @change="load", :disabled="!is_ready",
|
||||
style="max-width:100%")
|
||||
option(v-for="file in state.files", :value="file") {{file}}
|
||||
button.submit-macros(title="Save Macros",@click="saveMacros",style="height:100px;width:100px;font-weight:normal")
|
||||
button.submit-macros(title="Save Macros",@click="saveMacros",style="height:100px;width:100px;font-weight:normal") Save Macros
|
||||
|
||||
gcode-viewer
|
||||
|
||||
Reference in New Issue
Block a user