diff --git a/client/src/designtypes/Spring/Compression/migrate.js b/client/src/designtypes/Spring/Compression/migrate.js index 7c93aee7..be380ca1 100644 --- a/client/src/designtypes/Spring/Compression/migrate.js +++ b/client/src/designtypes/Spring/Compression/migrate.js @@ -310,21 +310,7 @@ export function migrate(design) { // Remove ioclass from all Symbol Table entries design.symbol_table.forEach((element) => { // For each Symbol Table entry delete element.ioclass; - // Added to migration on 10/15/2023 after finding #862 Issue - if (element.value === null) { - element.value = 1; - } - if (element.cmin === null) { - element.cmin = element.value; - } - if (element.cmax === null) { - element.cmax = element.value; - } }); - // Added to migration on 10/15/2023 after finding #862 Issue - if (design.result.objective_value === null) { - design.result.objective_value = 0.0; - } // #609 Add standard size table for metric Outside Diameters // Update Material_Type = 31 table and Material_File = 34 value // console.log('Material_File.value=',design.symbol_table[34].value,'Material_Type.table=',design.symbol_table[31].table) @@ -375,8 +361,8 @@ export function migrate(design) { case '12': // Current model version // console.log('Convert from 12 to 13'); - // Added to migration on 10/21/2023 after finding #855 Issue design.symbol_table.forEach((element) => { // For each Symbol Table entry + // Added to migration on 10/21/2023 after finding #855 Issue if (element.lmin === undefined) { element.lmin = 0; } @@ -389,7 +375,20 @@ export function migrate(design) { if (element.cmax === undefined) { element.cmax = element.value; } + // Added to migration on 10/15/2023 after finding #862 Issue + if (element.value === null) { + element.value = 1; + } + if (element.cmin === null) { + element.cmin = element.value; + } + if (element.cmax === null) { + element.cmax = element.value; + } }); + if (design.result.objective_value === null) { + design.result.objective_value = 0.0; + } // migrated_design.version = '13'; // last thing... set the migrated model version break; // Do not copy this break diff --git a/client/src/designtypes/Spring/Extension/migrate.js b/client/src/designtypes/Spring/Extension/migrate.js index 048d4833..92262403 100644 --- a/client/src/designtypes/Spring/Extension/migrate.js +++ b/client/src/designtypes/Spring/Extension/migrate.js @@ -257,21 +257,7 @@ export function migrate(design) { // Remove ioclass from all Symbol Table entries design.symbol_table.forEach((element) => { // For each Symbol Table entry delete element.ioclass; - // Added to migration on 10/15/2023 after finding #862 Issue - if (element.value === null) { - element.value = 1; - } - if (element.cmin === null) { - element.cmin = element.value; - } - if (element.cmax === null) { - element.cmax = element.value; - } }); - // Added to migration on 10/15/2023 after finding #862 Issue - if (design.result.objective_value === null) { - design.result.objective_value = 0.0; - } // #609 Add standard size table for metric Outside Diameters // Update Material_Type = 37 table and Material_File = 40 value // console.log('Material_File.value=',design.symbol_table[40].value,'Material_Type.table=',design.symbol_table[37].table) @@ -322,8 +308,8 @@ export function migrate(design) { case '8': // Current model version // console.log('Convert from 8 to 9'); - // Added to migration on 10/21/2023 after finding #855 Issue design.symbol_table.forEach((element) => { // For each Symbol Table entry + // Added to migration on 10/21/2023 after finding #855 Issue if (element.lmin === undefined) { element.lmin = 0; } @@ -336,7 +322,20 @@ export function migrate(design) { if (element.cmax === undefined) { element.cmax = element.value; } + // Added to migration on 10/15/2023 after finding #862 Issue + if (element.value === null) { + element.value = 1; + } + if (element.cmin === null) { + element.cmin = element.value; + } + if (element.cmax === null) { + element.cmax = element.value; + } }); + if (design.result.objective_value === null) { + design.result.objective_value = 0.0; + } // migrated_design.version = '9'; // last thing... set the migrated model version break; // Do not copy this break diff --git a/client/src/designtypes/Spring/Torsion/migrate.js b/client/src/designtypes/Spring/Torsion/migrate.js index eaa3cc7b..a02e1e30 100644 --- a/client/src/designtypes/Spring/Torsion/migrate.js +++ b/client/src/designtypes/Spring/Torsion/migrate.js @@ -229,21 +229,7 @@ export function migrate(design) { // Remove ioclass from all Symbol Table entries design.symbol_table.forEach((element) => { // For each Symbol Table entry delete element.ioclass; - // Added to migration on 10/15/2023 after finding #862 Issue - if (element.value === null) { - element.value = 1; - } - if (element.cmin === null) { - element.cmin = element.value; - } - if (element.cmax === null) { - element.cmax = element.value; - } }); - // Added to migration on 10/15/2023 after finding #862 Issue - if (design.result.objective_value === null) { - design.result.objective_value = 0.0; - } // #609 Add standard size table for metric Outside Diameters // Update Material_Type = 31 table and Material_File = 36 value // console.log('Material_File.value=',design.symbol_table[36].value,'Material_Type.table=',design.symbol_table[31].table) @@ -300,8 +286,8 @@ export function migrate(design) { case '8': // Current model version // console.log('Convert from 8 to 9'); - // Added to migration on 10/21/2023 after finding #855 Issue design.symbol_table.forEach((element) => { // For each Symbol Table entry + // Added to migration on 10/21/2023 after finding #855 Issue if (element.lmin === undefined) { element.lmin = 0; } @@ -314,7 +300,21 @@ export function migrate(design) { if (element.cmax === undefined) { element.cmax = element.value; } + // Added to migration on 10/15/2023 after finding #862 Issue + if (element.value === null) { + element.value = 1; + } + if (element.cmin === null) { + element.cmin = element.value; + } + if (element.cmax === null) { + element.cmax = element.value; + } }); + if (design.result.objective_value === null) { + design.result.objective_value = 0.0; + } +>>>>>>> refs/remotes/origin/862 // migrated_design.version = '9'; // last thing... set the migrated model version break; // Do not copy this break diff --git a/client/src/menus/View/ViewSymbolTable.jsx b/client/src/menus/View/ViewSymbolTable.jsx index f7846d79..900fca49 100644 --- a/client/src/menus/View/ViewSymbolTable.jsx +++ b/client/src/menus/View/ViewSymbolTable.jsx @@ -85,7 +85,7 @@ class ViewSymbolTable extends Component {