varmap_data=conn.QueryFirstOrDefault<dc_base_mother_sku_map_dto>(" select t1.*,t2.warehouse_name from dc_base_mother_sku_map as t1 left join dc_base_warehouse as t2 on t1.warehouse_code = t2.warehouse_code where t1.id=@id ",new{id=item});
conn.Execute(" update dc_base_mother_sku_map set is_main=0 where mother_sku_warehouse_code=@mother_sku_warehouse_code ",new{mother_sku_warehouse_code=map_data.mother_sku_warehouse_code});
conn.Execute(" update dc_base_mother_sku_map set is_main=1 where id=@id ",new{id=item});