|
@@ -746,9 +746,18 @@ function assembleFields(fieldList, rstDataArr, $PROJECT) {
|
|
|
vrst.splice(0,1);
|
|
|
}
|
|
|
} else if (field.Precision.type === 'flexible') {
|
|
|
+ console.log('field.Precision.flexibleMapExpression: ' + field.Precision.flexibleMapExpression);
|
|
|
const vrst = eval(field.Precision.flexibleMapExpression);
|
|
|
if (vrst && vrst.length === 1) {
|
|
|
- field.flexiblePrecisionRefObj = vrst[0];
|
|
|
+ const tmpFlexObj = []; // 计量的动态精度对象与建筑/养护有所不同,需要重新生成
|
|
|
+ for (const uKey in vrst[0]) {
|
|
|
+ const tmpFObj = { unit: vrst[0][uKey].unit, decimal: vrst[0][uKey].value };
|
|
|
+ if (uKey === 'other') {
|
|
|
+ tmpFObj.unit = '其他未列单位';
|
|
|
+ }
|
|
|
+ tmpFlexObj.push(tmpFObj);
|
|
|
+ }
|
|
|
+ field.flexiblePrecisionRefObj = tmpFlexObj;
|
|
|
vrst.splice(0, 1);
|
|
|
}
|
|
|
}
|