|
|
@@ -4,7 +4,7 @@ import evaluate from 'evaluator.js';
|
|
|
// 关键字组
|
|
|
export interface IKeywordItem {
|
|
|
optionCode: string; // 选项号
|
|
|
- coe: string;
|
|
|
+ coe: string; // 系数 *1.29
|
|
|
}
|
|
|
|
|
|
export interface IInfoPriceMain {
|
|
|
@@ -25,7 +25,7 @@ const replaceAll = (FindText: RegExp | string, RepText: string, str: string): st
|
|
|
* keywordItems : 关键字列表
|
|
|
*/
|
|
|
export const calcMaterialExp = (infoPrice: IInfoPriceMain, keywordItems: IKeywordItem[]) => {
|
|
|
- const preCodeLength = 4; // 别名编码位数,可能要改成5位或6位
|
|
|
+ const preCodeLength = 5; // 别名编码位数,可能要改成5位或6位
|
|
|
const decimal = 2; // 小数位数
|
|
|
const groupStr = infoPrice.classCode.substr(preCodeLength);
|
|
|
let { expString } = infoPrice; // 计算式
|