|
@@ -6,7 +6,12 @@ featureObj = {
|
|
|
};
|
|
|
|
|
|
$(document).ready(function () {
|
|
|
- $("#featureList").val(JSON.stringify(JSON.parse(featureList),null,4));
|
|
|
+ try {
|
|
|
+ $("#featureList").val(JSON.stringify(JSON.parse($("#originalFeature").val()),null,4));
|
|
|
+ }catch (err){
|
|
|
+ $("#featureList").val(featureList);
|
|
|
+ console.log(err);
|
|
|
+ }
|
|
|
|
|
|
$("#format").click( function() {
|
|
|
try {
|
|
@@ -22,8 +27,11 @@ $(document).ready(function () {
|
|
|
try {
|
|
|
let libID = $("#libID").val();
|
|
|
let jsonText = $("#featureList").val();
|
|
|
+ if(jsonText.indexOf("'")!=-1){
|
|
|
+ alert("输入的格式不能包含 ' 位于:"+jsonText.substr(jsonText.indexOf("'")-15,18));
|
|
|
+ return;
|
|
|
+ }
|
|
|
let newFeature = await ajaxPost("/projectFeature/saveLib",{query:{ID:libID},data:{feature:JSON.parse(jsonText)}});
|
|
|
- console.log(newFeature);
|
|
|
}catch (err){
|
|
|
console.log(err);
|
|
|
alert("保存失败,请查看输入数据");
|
|
@@ -32,20 +40,20 @@ $(document).ready(function () {
|
|
|
$("#createNormal").click(async function() {
|
|
|
let projectFeature = [
|
|
|
{dispName: '工程专业', key: 'engineering', value: ''},//只读,用户新建单位工程时选择的值
|
|
|
- {dispName: '工程类型', key: 'projType', value: ''},
|
|
|
- {dispName: '结构类型', key: 'structureType', value: ''},
|
|
|
- {dispName: '基础类型', key: 'baseType', value: ''},
|
|
|
- {dispName: '建筑特征', key: 'buildingFeature', value: ''},
|
|
|
- {dispName: '建筑面积(m2)', key: 'buildingArea', value: ''},
|
|
|
- {dispName: '其中地下室建筑面积(m2)', key: 'basementBuildingArea', value: ''},
|
|
|
- {dispName: '总层数', key: 'totalFloors', value: ''},
|
|
|
- {dispName: '地下室层数(+/-0.00以下)', key: 'basementFloors', value: ''},
|
|
|
- {dispName: '建筑层数(+/-0.00以下)', key: 'buildingFloors', value: ''},
|
|
|
- {dispName: '建筑物总高度(m)', key: 'buildingHeight', value: ''},
|
|
|
- {dispName: '地下室总高度(m)', key: 'basementHeight', value: ''},
|
|
|
- {dispName: '首层高度(m)', key: 'firstFloorHeight', value: ''},
|
|
|
- {dispName: '裙楼高度(m)', key: 'podiumBuildingHeight', value: ''},
|
|
|
- {dispName: '标准层高度(m)', key: 'standardFloorHeight', value: ''},
|
|
|
+ {dispName: '工程类型', key: 'projType', value: '',cellType:'comboBox',options:"住宅@公共建筑@厂房@办公"},
|
|
|
+ {dispName: '结构类型', key: 'structureType', value: '',cellType:'comboBox',options:"排架结构@框架结构@现浇、框架结构@预制、砖混结构@外砖内模@内浇外挂@钢结构"},
|
|
|
+ {dispName: '基础类型', key: 'baseType', value: '',cellType:'comboBox',options:"带基@框排架柱距6m以内@框排架柱距6m以外@满基筏式@满基板式@满基箱式@独立基础"},
|
|
|
+ {dispName: '建筑特征', key: 'buildingFeature', value: '',cellType:'comboBox',options:"点式@凹式@凸式@Y式@其他"},
|
|
|
+ {dispName: '建筑面积(m2)', key: 'buildingArea', value: '',cellType:'number'},
|
|
|
+ {dispName: '其中地下室建筑面积(m2)', key: 'basementBuildingArea', value: '',cellType:'number'},
|
|
|
+ {dispName: '总层数', key: 'totalFloors', value: '',cellType:'number'},
|
|
|
+ {dispName: '地下室层数(+/-0.00以下)', key: 'basementFloors', value: '',cellType:'number'},
|
|
|
+ {dispName: '建筑层数(+/-0.00以下)', key: 'buildingFloors', value: '',cellType:'number'},
|
|
|
+ {dispName: '建筑物总高度(m)', key: 'buildingHeight', value: '',cellType:'number'},
|
|
|
+ {dispName: '地下室总高度(m)', key: 'basementHeight', value: '',cellType:'number'},
|
|
|
+ {dispName: '首层高度(m)', key: 'firstFloorHeight', value: '',cellType:'number'},
|
|
|
+ {dispName: '裙楼高度(m)', key: 'podiumBuildingHeight', value: '',cellType:'number'},
|
|
|
+ {dispName: '标准层高度(m)', key: 'standardFloorHeight', value: '',cellType:'number'},
|
|
|
{dispName: '基础材料及装饰', key: 'baseMaterial', value: ''},
|
|
|
{dispName: '楼地面材料及装饰', key: 'flooringMaterial', value: ''},
|
|
|
{dispName: '外墙材料及装饰', key: 'exteriorWallMaterial', value: ''},
|