|
@@ -110,7 +110,8 @@ public class RecordDataUpdataHandle extends BaseHandle implements IRecordDataUpd
|
|
|
for (String key : queryDB.keySet()) {
|
|
|
condition=condition+"and "+key+"='"+queryDB.get(key)+"'";
|
|
|
}
|
|
|
- String updateSql="update "+JfGridConfigModel.TABLENAME+" set json_data=json_data #- '{"+keyName+"}' where 1=1 " +condition;
|
|
|
+// String updateSql="update "+JfGridConfigModel.TABLENAME+" set json_data=json_data #- '{"+keyName+"}' where 1=1 " +condition;
|
|
|
+ String updateSql="update "+JfGridConfigModel.TABLENAME+" set json_data=jsonb_set(json_data,'{" + keyName + "}', '{}', false) where 1=1 " +condition;
|
|
|
log.info("rmCellDataValue--"+updateSql);
|
|
|
jdbcTemplate_postgresql.update(updateSql);
|
|
|
return true;
|
|
@@ -512,7 +513,7 @@ public class RecordDataUpdataHandle extends BaseHandle implements IRecordDataUpd
|
|
|
word=word+","+position;
|
|
|
}
|
|
|
//(jsonb_v,'{myinfo,celldata,0}','{"c":1,"r":1,"v":{"con":"str"}}',false)
|
|
|
- String updateSql="update "+JfGridConfigModel.TABLENAME+" set json_data=jsonb_set(json_data,'{"+word+"}','"+db.toString()+"',false) where 1=1 " +condition;
|
|
|
+ String updateSql="update "+JfGridConfigModel.TABLENAME+" set json_data=jsonb_set(json_data,'{"+word+"}','"+db.toString()+"',true) where 1=1 " +condition;
|
|
|
log.info("updateSql:"+updateSql);
|
|
|
jdbcTemplate_postgresql.update(updateSql,arr.toArray());
|
|
|
return true;
|