Commit 019ab884 by 高晓磊

添加排序字段&&合并冲突解决

parent 39f84e76
package com.xyst.dinas.biz.config; package com.xyst.dinas.biz.config;
import com.beecode.amino.metadata.runtime.MetadataMech;
import com.beecode.bcp.type.KClass;
import com.beecode.bcp.type.TypeConstants;
import com.xyst.dinas.biz.constant.StationConstant;
import com.xyst.dinas.biz.internal.StationInfoQueryProcessor;
import com.xyst.dinas.biz.internal.dao.StationDaoImpl;
import com.xyst.dinas.biz.internal.service.StationServiceImpl;
import com.xyst.dinas.biz.web.StationController;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Qualifier;
import org.springframework.context.annotation.Bean; import org.springframework.context.annotation.Bean;
import com.xyst.dinas.biz.dao.PositionDao; import com.xyst.dinas.biz.dao.PositionDao;
...@@ -8,6 +18,7 @@ import com.xyst.dinas.biz.internal.dao.PositionDaoImpl; ...@@ -8,6 +18,7 @@ import com.xyst.dinas.biz.internal.dao.PositionDaoImpl;
import com.xyst.dinas.biz.internal.service.PositionServiceImpl; import com.xyst.dinas.biz.internal.service.PositionServiceImpl;
import com.xyst.dinas.biz.service.PositionService; import com.xyst.dinas.biz.service.PositionService;
import com.xyst.dinas.biz.web.PositionController; import com.xyst.dinas.biz.web.PositionController;
import org.springframework.core.io.ClassPathResource;
public class StationConfiguration { public class StationConfiguration {
...@@ -30,4 +41,34 @@ public class StationConfiguration { ...@@ -30,4 +41,34 @@ public class StationConfiguration {
public StationInfoQueryProcessor createStationInfoQueryProcessor() { public StationInfoQueryProcessor createStationInfoQueryProcessor() {
return new StationInfoQueryProcessor(); return new StationInfoQueryProcessor();
} }
@Autowired
@Qualifier(TypeConstants.CLASS_MECH)
private MetadataMech<KClass> typeMech;
//StationDaoImpl相关bean配置
@Bean
public StationDaoImpl stationDaoImpl() {
return new StationDaoImpl();
}
@Bean
public StationServiceImpl stationServiceImpl(){
return new StationServiceImpl();
}
@Bean
public StationController stationController(){
return new StationController();
}
@Bean(StationConstant.ENTITY)
public KClass stationInfoEntity() {
return typeMech.createStaticBeanByResource(
new ClassPathResource("/com/xyst/dinas/biz/datamodel/Station.jmx", KClass.class));
}
} }
...@@ -29,31 +29,62 @@ ...@@ -29,31 +29,62 @@
</property> </property>
<many-to-one name="department" entity-name="com.beecode.bap.department.datamodel.Department" fetch="select"> <many-to-one name="department" entity-name="com.beecode.bap.department.datamodel.Department" fetch="select">
<column name="department" not-null="false"/> <column name="department" not-null="false">
<comment>所属部门</comment>
</column>
</many-to-one> </many-to-one>
<property name="stationName" type="nstring" not-null="true"> <property name="stationName" type="nstring" not-null="true">
<column name="station_name" length="30" /> <column name="station_name" length="30" >
<comment>场站名称</comment>
</column>
</property> </property>
<property name="stationAddress" type="nstring" length="80" not-null="false"> <property name="stationAddress" type="nstring" length="80" not-null="false">
<column name="station_address"/> <column name="station_address">
<comment>场站地址</comment>
</column>
</property> </property>
<property name="stationStatus" type="integer" not-null="true"> <property name="stationStatus" type="integer" not-null="true">
<column name="station_status" /> <column name="station_status" >
<comment>场站状态,0已停业1经营中</comment>
</column>
</property> </property>
<property name="stationCoordinate" type="nstring" not-null="false"> <property name="stationCoordinate" type="nstring" not-null="false">
<column name="station_coordinate"/> <column name="station_coordinate">
<comment>场站的坐标按照逗号分隔</comment>
</column>
</property> </property>
<property name="linkMan" type="nstring" not-null="false"> <property name="linkMan" type="nstring" not-null="false">
<column name="link_man"/> <column name="link_man">
<comment>联系人</comment>
</column>
</property> </property>
<property name="openingDate" type="timestamp" not-null="false"> <property name="openingDate" type="timestamp" not-null="false">
<column name="opening_date"/> <column name="opening_date">
<comment>开业时间</comment>
</column>
</property> </property>
<property name="telephone" type="nstring" not-null="false"> <property name="telephone" type="nstring" not-null="false">
<column name="telephone" length="50"/> <column name="telephone" length="50">
<comment>联系方式</comment>
</column>
</property> </property>
<property name="reason" type="nstring" not-null="false"> <property name="reason" type="nstring" not-null="false">
<column name="reason" length="300"/> <column name="reason" length="300" >
<comment>备注</comment>
</column>
</property>
<property name="sort_order" type="int" not-null="true" unique="true" update="false" insert="false" index="station_sort_index" >
<column name="sort_order" length="10">
<comment >排序</comment>
</column>
</property> </property>
</class> </class>
</hibernate-mapping> </hibernate-mapping>
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment