增加公司id和公司名称字段到设备信息模型,并更新相关查询
This commit is contained in:
parent
e4e81edd54
commit
7cd15cba1a
|
|
@ -91,6 +91,12 @@ public class DevInfo extends BaseEntity {
|
|||
@NotBlank(message = "单位不能为空")
|
||||
private String unitName;
|
||||
|
||||
@ApiModelProperty("公司id -- 陕西自己存入")
|
||||
private String orgId;
|
||||
|
||||
@ApiModelProperty("公司名称--陕西自己存入")
|
||||
private String orgName;
|
||||
|
||||
/**
|
||||
* 类型id
|
||||
*/
|
||||
|
|
|
|||
|
|
@ -414,6 +414,7 @@ public class DevInfoServiceImpl implements DevInfoService {
|
|||
Long userId = SecurityUtils.getLoginUser().getUserid();
|
||||
//保存用户信息
|
||||
devInfo.setCreator(userId).setOwnId(userId);
|
||||
// 取消编码自动生成,由陕西自行传入编码
|
||||
// if (org.apache.commons.lang3.StringUtils.isBlank(code)) {
|
||||
// code = getString();
|
||||
// }
|
||||
|
|
|
|||
|
|
@ -16,6 +16,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||
<result property="provinceId" column="province_id" />
|
||||
<result property="cityId" column="city_id" />
|
||||
<result property="areaId" column="area_id" />
|
||||
<result property="orgId" column="org_id" />
|
||||
<result property="orgName" column="org_name" />
|
||||
<result property="brand" column="brand" />
|
||||
<result property="modelName" column="model_name" />
|
||||
<result property="productionDate" column="production_date" />
|
||||
|
|
@ -45,7 +47,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||
|
||||
<sql id="selectDevInfoVo">
|
||||
select ma_id, device_name, device_weight, device_count, code, identify_code, type_id, ma_status, lease_scope, location, province_id, city_id, area_id, brand, model_name, production_date, working_hours, serial_number,
|
||||
pic_url, js_month_price, js_day_price, description, gps_code, own_co, create_time, level_type,collect_code,
|
||||
pic_url, js_month_price, js_day_price, description, gps_code, own_co, create_time, level_type, collect_code, org_id, org_name,
|
||||
creator, update_time, person, person_phone, update_by, specification, deposit, is_operator, is_active, update_time, update_by
|
||||
from ma_dev_info
|
||||
</sql>
|
||||
|
|
@ -62,6 +64,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||
d.device_count as deviceCount,
|
||||
d.device_unit_type as deviceUnitType,
|
||||
d.type_id as typeId,
|
||||
d.org_id as orgId,
|
||||
d.org_name as orgName,
|
||||
mt4.type_name as typeName,
|
||||
mt4.unit_name as unitName,
|
||||
d.ma_status as maStatus,
|
||||
|
|
@ -242,6 +246,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||
d.type_id as typeId,
|
||||
d.check_date as checkDate,
|
||||
d.check_cycle as checkCycle,
|
||||
d.org_id as orgId,
|
||||
d.org_namee as orgName,
|
||||
mt4.type_name as typeName,
|
||||
mt4.unit_name as unitName,
|
||||
mt4.manage_type as manageType,
|
||||
|
|
@ -330,6 +336,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||
<if test="description != null and description != ''">`description`,</if>
|
||||
<if test="gpsCode != null and gpsCode != ''">gps_code,</if>
|
||||
<if test="companyId != null and companyId != ''">own_co,</if>
|
||||
<if test="orgId != null">org_id,</if>
|
||||
<if test="orgName != null and orgName != ''">org_name,</if>
|
||||
<if test="person != null and person != ''">person,</if>
|
||||
<if test="personPhone != null and personPhone != ''">person_phone,</if>
|
||||
<if test="levelType != null and levelType != ''">level_type,</if>
|
||||
|
|
@ -379,6 +387,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||
<if test="description != null and description != ''">#{description},</if>
|
||||
<if test="gpsCode != null and gpsCode != ''">#{gpsCode},</if>
|
||||
<if test="companyId != null and companyId != ''">#{companyId},</if>
|
||||
<if test="orgId != null">#{orgId},</if>
|
||||
<if test="orgName != null and orgName != ''">#{orgName},</if>
|
||||
<if test="person != null and person != ''">#{person},</if>
|
||||
<if test="personPhone != null and personPhone != ''">#{personPhone},</if>
|
||||
<if test="levelType != null and levelType != ''">#{levelType},</if>
|
||||
|
|
@ -436,6 +446,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||
<if test="location != null">location = #{location},</if>
|
||||
<if test="provinceId != null">province_id = #{provinceId},</if>
|
||||
<if test="cityId != null">city_id = #{cityId},</if>
|
||||
<if test="orgId != null">org_id = #{orgId},</if>
|
||||
<if test="orgName != null and orgName != ''">org_name = #{orgName},</if>
|
||||
<if test="areaId != null">area_id = #{areaId},</if>
|
||||
<if test="brand != null">brand = #{brand},</if>
|
||||
<if test="modelName != null">model_name = #{modelName},</if>
|
||||
|
|
|
|||
Loading…
Reference in New Issue