提交 b75ee1b1 编写于 作者: ibizdev's avatar ibizdev

xignzi006 发布系统代码

上级 ba2d6387
...@@ -573,6 +573,22 @@ public class Purchase_order extends EntityMP implements Serializable { ...@@ -573,6 +573,22 @@ public class Purchase_order extends EntityMP implements Serializable {
@JSONField(name = "picking_type_id") @JSONField(name = "picking_type_id")
@JsonProperty("picking_type_id") @JsonProperty("picking_type_id")
private Long pickingTypeId; private Long pickingTypeId;
/**
* ID
*/
@DEField(name = "requisition_id")
@TableField(value = "requisition_id")
@JSONField(name = "requisition_id")
@JsonProperty("requisition_id")
private Long requisitionId;
/**
*
*/
@JsonIgnore
@JSONField(serialize = false)
@TableField(exist = false)
private cn.ibizlab.businesscentral.core.odoo_purchase.domain.Purchase_requisition odooRequisition;
/** /**
* *
...@@ -902,6 +918,14 @@ public class Purchase_order extends EntityMP implements Serializable { ...@@ -902,6 +918,14 @@ public class Purchase_order extends EntityMP implements Serializable {
this.modify("picking_type_id",pickingTypeId); this.modify("picking_type_id",pickingTypeId);
} }
/**
* 设置 [ID]
*/
public void setRequisitionId(Long requisitionId){
this.requisitionId = requisitionId ;
this.modify("requisition_id",requisitionId);
}
@Override @Override
public Serializable getDefaultKey(boolean gen) { public Serializable getDefaultKey(boolean gen) {
......
...@@ -293,6 +293,13 @@ public class Purchase_orderSearchContext extends QueryWrapperContext<Purchase_or ...@@ -293,6 +293,13 @@ public class Purchase_orderSearchContext extends QueryWrapperContext<Purchase_or
this.getSearchCond().eq("picking_type_id", n_picking_type_id_eq); this.getSearchCond().eq("picking_type_id", n_picking_type_id_eq);
} }
} }
private Long n_requisition_id_eq;//[ID]
public void setN_requisition_id_eq(Long n_requisition_id_eq) {
this.n_requisition_id_eq = n_requisition_id_eq;
if(!ObjectUtils.isEmpty(this.n_requisition_id_eq)){
this.getSearchCond().eq("requisition_id", n_requisition_id_eq);
}
}
/** /**
* 启用快速搜索 * 启用快速搜索
......
...@@ -62,6 +62,8 @@ public interface Purchase_orderMapper extends BaseMapper<Purchase_order>{ ...@@ -62,6 +62,8 @@ public interface Purchase_orderMapper extends BaseMapper<Purchase_order>{
@Delete("${sql}") @Delete("${sql}")
boolean deleteBySQL(@Param("sql") String sql, @Param("et")Map param); boolean deleteBySQL(@Param("sql") String sql, @Param("et")Map param);
List<Purchase_order> selectByRequisitionId(@Param("id") Serializable id) ;
List<Purchase_order> selectByFiscalPositionId(@Param("id") Serializable id) ; List<Purchase_order> selectByFiscalPositionId(@Param("id") Serializable id) ;
List<Purchase_order> selectByIncotermId(@Param("id") Serializable id) ; List<Purchase_order> selectByIncotermId(@Param("id") Serializable id) ;
......
...@@ -38,6 +38,8 @@ public interface IPurchase_orderService extends IService<Purchase_order>{ ...@@ -38,6 +38,8 @@ public interface IPurchase_orderService extends IService<Purchase_order>{
boolean save(Purchase_order et) ; boolean save(Purchase_order et) ;
void saveBatch(List<Purchase_order> list) ; void saveBatch(List<Purchase_order> list) ;
Page<Purchase_order> searchDefault(Purchase_orderSearchContext context) ; Page<Purchase_order> searchDefault(Purchase_orderSearchContext context) ;
List<Purchase_order> selectByRequisitionId(Long id) ;
void removeByRequisitionId(Long id) ;
List<Purchase_order> selectByFiscalPositionId(Long id) ; List<Purchase_order> selectByFiscalPositionId(Long id) ;
void removeByFiscalPositionId(Long id) ; void removeByFiscalPositionId(Long id) ;
List<Purchase_order> selectByIncotermId(Long id) ; List<Purchase_order> selectByIncotermId(Long id) ;
......
...@@ -59,6 +59,9 @@ public class Purchase_orderServiceImpl extends ServiceImpl<Purchase_orderMapper, ...@@ -59,6 +59,9 @@ public class Purchase_orderServiceImpl extends ServiceImpl<Purchase_orderMapper,
protected cn.ibizlab.businesscentral.core.odoo_purchase.service.IPurchase_order_lineService purchaseOrderLineService; protected cn.ibizlab.businesscentral.core.odoo_purchase.service.IPurchase_order_lineService purchaseOrderLineService;
@Autowired @Autowired
@Lazy @Lazy
protected cn.ibizlab.businesscentral.core.odoo_purchase.service.IPurchase_requisitionService purchaseRequisitionService;
@Autowired
@Lazy
protected cn.ibizlab.businesscentral.core.odoo_account.service.IAccount_fiscal_positionService accountFiscalPositionService; protected cn.ibizlab.businesscentral.core.odoo_account.service.IAccount_fiscal_positionService accountFiscalPositionService;
@Autowired @Autowired
@Lazy @Lazy
...@@ -188,6 +191,16 @@ public class Purchase_orderServiceImpl extends ServiceImpl<Purchase_orderMapper, ...@@ -188,6 +191,16 @@ public class Purchase_orderServiceImpl extends ServiceImpl<Purchase_orderMapper,
} }
@Override
public List<Purchase_order> selectByRequisitionId(Long id) {
return baseMapper.selectByRequisitionId(id);
}
@Override
public void removeByRequisitionId(Long id) {
this.remove(new QueryWrapper<Purchase_order>().eq("requisition_id",id));
}
@Override @Override
public List<Purchase_order> selectByFiscalPositionId(Long id) { public List<Purchase_order> selectByFiscalPositionId(Long id) {
return baseMapper.selectByFiscalPositionId(id); return baseMapper.selectByFiscalPositionId(id);
......
...@@ -48,6 +48,9 @@ import org.springframework.util.StringUtils; ...@@ -48,6 +48,9 @@ import org.springframework.util.StringUtils;
@Service("Purchase_requisitionServiceImpl") @Service("Purchase_requisitionServiceImpl")
public class Purchase_requisitionServiceImpl extends ServiceImpl<Purchase_requisitionMapper, Purchase_requisition> implements IPurchase_requisitionService { public class Purchase_requisitionServiceImpl extends ServiceImpl<Purchase_requisitionMapper, Purchase_requisition> implements IPurchase_requisitionService {
@Autowired
@Lazy
protected cn.ibizlab.businesscentral.core.odoo_purchase.service.IPurchase_orderService purchaseOrderService;
@Autowired @Autowired
@Lazy @Lazy
protected cn.ibizlab.businesscentral.core.odoo_purchase.service.IPurchase_requisition_lineService purchaseRequisitionLineService; protected cn.ibizlab.businesscentral.core.odoo_purchase.service.IPurchase_requisition_lineService purchaseRequisitionLineService;
......
...@@ -5,7 +5,7 @@ ...@@ -5,7 +5,7 @@
<!--该方法用于重写mybatis中selectById方法,以实现查询逻辑属性--> <!--该方法用于重写mybatis中selectById方法,以实现查询逻辑属性-->
<select id="selectById" resultMap="Purchase_orderResultMap" databaseId="postgresql"> <select id="selectById" resultMap="Purchase_orderResultMap" databaseId="postgresql">
<![CDATA[select t1.* from (SELECT t1.ACCESS_TOKEN, t1.AMOUNT_TAX, t1.AMOUNT_TOTAL, t1.AMOUNT_UNTAXED, t1.COMPANY_ID, t61.NAME AS COMPANY_ID_TEXT, t1.CREATE_DATE, t1.CREATE_UID, t121.NAME AS CREATE_UID_TEXT, t1.CURRENCY_ID, t41.NAME AS CURRENCY_ID_TEXT, t1.DATE_APPROVE, t1.DATE_ORDER, t1.DATE_PLANNED, t1.DEST_ADDRESS_ID, t71.NAME AS DEST_ADDRESS_ID_TEXT, t1.FISCAL_POSITION_ID, t31.NAME AS FISCAL_POSITION_ID_TEXT, t1.GROUP_ID, t1.ID, t1.INCOTERM_ID, t151.NAME AS INCOTERM_ID_TEXT, t1.INVOICE_COUNT, t1.INVOICE_STATUS, t1.MESSAGE_MAIN_ATTACHMENT_ID, t1.NAME, t1.NOTES, t1.ORIGIN, t1.PARTNER_ID, t131.NAME AS PARTNER_ID_TEXT, t1.PARTNER_REF, t1.PAYMENT_TERM_ID, t101.NAME AS PAYMENT_TERM_ID_TEXT, t1.PICKING_COUNT, t1.PICKING_TYPE_ID, t141.NAME AS PICKING_TYPE_ID_TEXT, t1.STATE, t1.USER_ID, t21.NAME AS USER_ID_TEXT, t1.WRITE_DATE, t1.WRITE_UID, t91.NAME AS WRITE_UID_TEXT FROM PURCHASE_ORDER t1 LEFT JOIN RES_USERS t11 ON t1.USER_ID = t11.ID LEFT JOIN RES_PARTNER t21 ON t11.PARTNER_ID = t21.ID LEFT JOIN ACCOUNT_FISCAL_POSITION t31 ON t1.FISCAL_POSITION_ID = t31.ID LEFT JOIN RES_CURRENCY t41 ON t1.CURRENCY_ID = t41.ID LEFT JOIN RES_COMPANY t51 ON t1.COMPANY_ID = t51.ID LEFT JOIN RES_PARTNER t61 ON t51.PARTNER_ID = t61.ID LEFT JOIN RES_PARTNER t71 ON t1.DEST_ADDRESS_ID = t71.ID LEFT JOIN RES_USERS t81 ON t1.WRITE_UID = t81.ID LEFT JOIN RES_PARTNER t91 ON t81.PARTNER_ID = t91.ID LEFT JOIN ACCOUNT_PAYMENT_TERM t101 ON t1.PAYMENT_TERM_ID = t101.ID LEFT JOIN RES_USERS t111 ON t1.CREATE_UID = t111.ID LEFT JOIN RES_PARTNER t121 ON t111.PARTNER_ID = t121.ID LEFT JOIN RES_PARTNER t131 ON t1.PARTNER_ID = t131.ID LEFT JOIN STOCK_PICKING_TYPE t141 ON t1.PICKING_TYPE_ID = t141.ID LEFT JOIN ACCOUNT_INCOTERMS t151 ON t1.INCOTERM_ID = t151.ID ) t1 where id=#{id}]]> <![CDATA[select t1.* from (SELECT t1.ACCESS_TOKEN, t1.AMOUNT_TAX, t1.AMOUNT_TOTAL, t1.AMOUNT_UNTAXED, t1.COMPANY_ID, t61.NAME AS COMPANY_ID_TEXT, t1.CREATE_DATE, t1.CREATE_UID, t121.NAME AS CREATE_UID_TEXT, t1.CURRENCY_ID, t41.NAME AS CURRENCY_ID_TEXT, t1.DATE_APPROVE, t1.DATE_ORDER, t1.DATE_PLANNED, t1.DEST_ADDRESS_ID, t71.NAME AS DEST_ADDRESS_ID_TEXT, t1.FISCAL_POSITION_ID, t31.NAME AS FISCAL_POSITION_ID_TEXT, t1.GROUP_ID, t1.ID, t1.INCOTERM_ID, t151.NAME AS INCOTERM_ID_TEXT, t1.INVOICE_COUNT, t1.INVOICE_STATUS, t1.MESSAGE_MAIN_ATTACHMENT_ID, t1.NAME, t1.NOTES, t1.ORIGIN, t1.PARTNER_ID, t131.NAME AS PARTNER_ID_TEXT, t1.PARTNER_REF, t1.PAYMENT_TERM_ID, t101.NAME AS PAYMENT_TERM_ID_TEXT, t1.PICKING_COUNT, t1.PICKING_TYPE_ID, t141.NAME AS PICKING_TYPE_ID_TEXT, t1.REQUISITION_ID, t1.STATE, t1.USER_ID, t21.NAME AS USER_ID_TEXT, t1.WRITE_DATE, t1.WRITE_UID, t91.NAME AS WRITE_UID_TEXT FROM PURCHASE_ORDER t1 LEFT JOIN RES_USERS t11 ON t1.USER_ID = t11.ID LEFT JOIN RES_PARTNER t21 ON t11.PARTNER_ID = t21.ID LEFT JOIN ACCOUNT_FISCAL_POSITION t31 ON t1.FISCAL_POSITION_ID = t31.ID LEFT JOIN RES_CURRENCY t41 ON t1.CURRENCY_ID = t41.ID LEFT JOIN RES_COMPANY t51 ON t1.COMPANY_ID = t51.ID LEFT JOIN RES_PARTNER t61 ON t51.PARTNER_ID = t61.ID LEFT JOIN RES_PARTNER t71 ON t1.DEST_ADDRESS_ID = t71.ID LEFT JOIN RES_USERS t81 ON t1.WRITE_UID = t81.ID LEFT JOIN RES_PARTNER t91 ON t81.PARTNER_ID = t91.ID LEFT JOIN ACCOUNT_PAYMENT_TERM t101 ON t1.PAYMENT_TERM_ID = t101.ID LEFT JOIN RES_USERS t111 ON t1.CREATE_UID = t111.ID LEFT JOIN RES_PARTNER t121 ON t111.PARTNER_ID = t121.ID LEFT JOIN RES_PARTNER t131 ON t1.PARTNER_ID = t131.ID LEFT JOIN STOCK_PICKING_TYPE t141 ON t1.PICKING_TYPE_ID = t141.ID LEFT JOIN ACCOUNT_INCOTERMS t151 ON t1.INCOTERM_ID = t151.ID ) t1 where id=#{id}]]>
</select> </select>
<!--通过mybatis将查询结果注入到entity中,通过配置autoMapping="true"由mybatis自动处理映射关系 --> <!--通过mybatis将查询结果注入到entity中,通过配置autoMapping="true"由mybatis自动处理映射关系 -->
...@@ -77,8 +77,11 @@ ...@@ -77,8 +77,11 @@
<result property="incotermId" column="incoterm_id" /> <result property="incotermId" column="incoterm_id" />
<result property="fiscalPositionId" column="fiscal_position_id" /> <result property="fiscalPositionId" column="fiscal_position_id" />
<result property="pickingTypeId" column="picking_type_id" /> <result property="pickingTypeId" column="picking_type_id" />
<result property="requisitionId" column="requisition_id" />
<!--通过mybatis自动注入关系属性[主实体],fetchType="lazy"为懒加载配置 -->
<association property="odooRequisition" javaType="cn.ibizlab.businesscentral.core.odoo_purchase.domain.Purchase_requisition" column="requisition_id" select="cn.ibizlab.businesscentral.core.odoo_purchase.mapper.Purchase_requisitionMapper.selectById" fetchType="lazy"></association>
<!--通过mybatis自动注入关系属性[主实体],fetchType="lazy"为懒加载配置 --> <!--通过mybatis自动注入关系属性[主实体],fetchType="lazy"为懒加载配置 -->
<association property="odooFiscalPosition" javaType="cn.ibizlab.businesscentral.core.odoo_account.domain.Account_fiscal_position" column="fiscal_position_id" select="cn.ibizlab.businesscentral.core.odoo_account.mapper.Account_fiscal_positionMapper.selectById" fetchType="lazy"></association> <association property="odooFiscalPosition" javaType="cn.ibizlab.businesscentral.core.odoo_account.domain.Account_fiscal_position" column="fiscal_position_id" select="cn.ibizlab.businesscentral.core.odoo_account.mapper.Account_fiscal_positionMapper.selectById" fetchType="lazy"></association>
<!--通过mybatis自动注入关系属性[主实体],fetchType="lazy"为懒加载配置 --> <!--通过mybatis自动注入关系属性[主实体],fetchType="lazy"为懒加载配置 -->
...@@ -103,6 +106,13 @@ ...@@ -103,6 +106,13 @@
<association property="odooPickingType" javaType="cn.ibizlab.businesscentral.core.odoo_stock.domain.Stock_picking_type" column="picking_type_id" select="cn.ibizlab.businesscentral.core.odoo_stock.mapper.Stock_picking_typeMapper.selectById" fetchType="lazy"></association> <association property="odooPickingType" javaType="cn.ibizlab.businesscentral.core.odoo_stock.domain.Stock_picking_type" column="picking_type_id" select="cn.ibizlab.businesscentral.core.odoo_stock.mapper.Stock_picking_typeMapper.selectById" fetchType="lazy"></association>
</resultMap> </resultMap>
<!--关系实体暴露select方法供主实体通过外键查询关系实体数据[实体关系名称:DER1N_PURCHASE_ORDER_PURCHASE_REQUISITION_REQUISITION_ID] -->
<select id="selectByRequisitionId" resultMap="Purchase_orderResultMap">
select t1.* from (
<include refid="Default" />
) t1
where requisition_id=#{id}
</select>
<!--关系实体暴露select方法供主实体通过外键查询关系实体数据[实体关系名称:DER1N_PURCHASE_ORDER__ACCOUNT_FISCAL_POSITION__FISCAL_POSITION_ID] --> <!--关系实体暴露select方法供主实体通过外键查询关系实体数据[实体关系名称:DER1N_PURCHASE_ORDER__ACCOUNT_FISCAL_POSITION__FISCAL_POSITION_ID] -->
<select id="selectByFiscalPositionId" resultMap="Purchase_orderResultMap"> <select id="selectByFiscalPositionId" resultMap="Purchase_orderResultMap">
select t1.* from ( select t1.* from (
...@@ -192,12 +202,12 @@ ...@@ -192,12 +202,12 @@
<!--数据查询[Default]--> <!--数据查询[Default]-->
<sql id="Default" databaseId="postgresql"> <sql id="Default" databaseId="postgresql">
<![CDATA[ SELECT t1.ACCESS_TOKEN, t1.AMOUNT_TAX, t1.AMOUNT_TOTAL, t1.AMOUNT_UNTAXED, t1.COMPANY_ID, t61.NAME AS COMPANY_ID_TEXT, t1.CREATE_DATE, t1.CREATE_UID, t121.NAME AS CREATE_UID_TEXT, t1.CURRENCY_ID, t41.NAME AS CURRENCY_ID_TEXT, t1.DATE_APPROVE, t1.DATE_ORDER, t1.DATE_PLANNED, t1.DEST_ADDRESS_ID, t71.NAME AS DEST_ADDRESS_ID_TEXT, t1.FISCAL_POSITION_ID, t31.NAME AS FISCAL_POSITION_ID_TEXT, t1.GROUP_ID, t1.ID, t1.INCOTERM_ID, t151.NAME AS INCOTERM_ID_TEXT, t1.INVOICE_COUNT, t1.INVOICE_STATUS, t1.MESSAGE_MAIN_ATTACHMENT_ID, t1.NAME, t1.ORIGIN, t1.PARTNER_ID, t131.NAME AS PARTNER_ID_TEXT, t1.PARTNER_REF, t1.PAYMENT_TERM_ID, t101.NAME AS PAYMENT_TERM_ID_TEXT, t1.PICKING_COUNT, t1.PICKING_TYPE_ID, t141.NAME AS PICKING_TYPE_ID_TEXT, t1.STATE, t1.USER_ID, t21.NAME AS USER_ID_TEXT, t1.WRITE_DATE, t1.WRITE_UID, t91.NAME AS WRITE_UID_TEXT FROM PURCHASE_ORDER t1 LEFT JOIN RES_USERS t11 ON t1.USER_ID = t11.ID LEFT JOIN RES_PARTNER t21 ON t11.PARTNER_ID = t21.ID LEFT JOIN ACCOUNT_FISCAL_POSITION t31 ON t1.FISCAL_POSITION_ID = t31.ID LEFT JOIN RES_CURRENCY t41 ON t1.CURRENCY_ID = t41.ID LEFT JOIN RES_COMPANY t51 ON t1.COMPANY_ID = t51.ID LEFT JOIN RES_PARTNER t61 ON t51.PARTNER_ID = t61.ID LEFT JOIN RES_PARTNER t71 ON t1.DEST_ADDRESS_ID = t71.ID LEFT JOIN RES_USERS t81 ON t1.WRITE_UID = t81.ID LEFT JOIN RES_PARTNER t91 ON t81.PARTNER_ID = t91.ID LEFT JOIN ACCOUNT_PAYMENT_TERM t101 ON t1.PAYMENT_TERM_ID = t101.ID LEFT JOIN RES_USERS t111 ON t1.CREATE_UID = t111.ID LEFT JOIN RES_PARTNER t121 ON t111.PARTNER_ID = t121.ID LEFT JOIN RES_PARTNER t131 ON t1.PARTNER_ID = t131.ID LEFT JOIN STOCK_PICKING_TYPE t141 ON t1.PICKING_TYPE_ID = t141.ID LEFT JOIN ACCOUNT_INCOTERMS t151 ON t1.INCOTERM_ID = t151.ID <![CDATA[ SELECT t1.ACCESS_TOKEN, t1.AMOUNT_TAX, t1.AMOUNT_TOTAL, t1.AMOUNT_UNTAXED, t1.COMPANY_ID, t61.NAME AS COMPANY_ID_TEXT, t1.CREATE_DATE, t1.CREATE_UID, t121.NAME AS CREATE_UID_TEXT, t1.CURRENCY_ID, t41.NAME AS CURRENCY_ID_TEXT, t1.DATE_APPROVE, t1.DATE_ORDER, t1.DATE_PLANNED, t1.DEST_ADDRESS_ID, t71.NAME AS DEST_ADDRESS_ID_TEXT, t1.FISCAL_POSITION_ID, t31.NAME AS FISCAL_POSITION_ID_TEXT, t1.GROUP_ID, t1.ID, t1.INCOTERM_ID, t151.NAME AS INCOTERM_ID_TEXT, t1.INVOICE_COUNT, t1.INVOICE_STATUS, t1.MESSAGE_MAIN_ATTACHMENT_ID, t1.NAME, t1.ORIGIN, t1.PARTNER_ID, t131.NAME AS PARTNER_ID_TEXT, t1.PARTNER_REF, t1.PAYMENT_TERM_ID, t101.NAME AS PAYMENT_TERM_ID_TEXT, t1.PICKING_COUNT, t1.PICKING_TYPE_ID, t141.NAME AS PICKING_TYPE_ID_TEXT, t1.REQUISITION_ID, t1.STATE, t1.USER_ID, t21.NAME AS USER_ID_TEXT, t1.WRITE_DATE, t1.WRITE_UID, t91.NAME AS WRITE_UID_TEXT FROM PURCHASE_ORDER t1 LEFT JOIN RES_USERS t11 ON t1.USER_ID = t11.ID LEFT JOIN RES_PARTNER t21 ON t11.PARTNER_ID = t21.ID LEFT JOIN ACCOUNT_FISCAL_POSITION t31 ON t1.FISCAL_POSITION_ID = t31.ID LEFT JOIN RES_CURRENCY t41 ON t1.CURRENCY_ID = t41.ID LEFT JOIN RES_COMPANY t51 ON t1.COMPANY_ID = t51.ID LEFT JOIN RES_PARTNER t61 ON t51.PARTNER_ID = t61.ID LEFT JOIN RES_PARTNER t71 ON t1.DEST_ADDRESS_ID = t71.ID LEFT JOIN RES_USERS t81 ON t1.WRITE_UID = t81.ID LEFT JOIN RES_PARTNER t91 ON t81.PARTNER_ID = t91.ID LEFT JOIN ACCOUNT_PAYMENT_TERM t101 ON t1.PAYMENT_TERM_ID = t101.ID LEFT JOIN RES_USERS t111 ON t1.CREATE_UID = t111.ID LEFT JOIN RES_PARTNER t121 ON t111.PARTNER_ID = t121.ID LEFT JOIN RES_PARTNER t131 ON t1.PARTNER_ID = t131.ID LEFT JOIN STOCK_PICKING_TYPE t141 ON t1.PICKING_TYPE_ID = t141.ID LEFT JOIN ACCOUNT_INCOTERMS t151 ON t1.INCOTERM_ID = t151.ID
]]> ]]>
</sql> </sql>
<!--数据查询[View]--> <!--数据查询[View]-->
<sql id="View" databaseId="postgresql"> <sql id="View" databaseId="postgresql">
<![CDATA[ SELECT t1.ACCESS_TOKEN, t1.AMOUNT_TAX, t1.AMOUNT_TOTAL, t1.AMOUNT_UNTAXED, t1.COMPANY_ID, t61.NAME AS COMPANY_ID_TEXT, t1.CREATE_DATE, t1.CREATE_UID, t121.NAME AS CREATE_UID_TEXT, t1.CURRENCY_ID, t41.NAME AS CURRENCY_ID_TEXT, t1.DATE_APPROVE, t1.DATE_ORDER, t1.DATE_PLANNED, t1.DEST_ADDRESS_ID, t71.NAME AS DEST_ADDRESS_ID_TEXT, t1.FISCAL_POSITION_ID, t31.NAME AS FISCAL_POSITION_ID_TEXT, t1.GROUP_ID, t1.ID, t1.INCOTERM_ID, t151.NAME AS INCOTERM_ID_TEXT, t1.INVOICE_COUNT, t1.INVOICE_STATUS, t1.MESSAGE_MAIN_ATTACHMENT_ID, t1.NAME, t1.NOTES, t1.ORIGIN, t1.PARTNER_ID, t131.NAME AS PARTNER_ID_TEXT, t1.PARTNER_REF, t1.PAYMENT_TERM_ID, t101.NAME AS PAYMENT_TERM_ID_TEXT, t1.PICKING_COUNT, t1.PICKING_TYPE_ID, t141.NAME AS PICKING_TYPE_ID_TEXT, t1.STATE, t1.USER_ID, t21.NAME AS USER_ID_TEXT, t1.WRITE_DATE, t1.WRITE_UID, t91.NAME AS WRITE_UID_TEXT FROM PURCHASE_ORDER t1 LEFT JOIN RES_USERS t11 ON t1.USER_ID = t11.ID LEFT JOIN RES_PARTNER t21 ON t11.PARTNER_ID = t21.ID LEFT JOIN ACCOUNT_FISCAL_POSITION t31 ON t1.FISCAL_POSITION_ID = t31.ID LEFT JOIN RES_CURRENCY t41 ON t1.CURRENCY_ID = t41.ID LEFT JOIN RES_COMPANY t51 ON t1.COMPANY_ID = t51.ID LEFT JOIN RES_PARTNER t61 ON t51.PARTNER_ID = t61.ID LEFT JOIN RES_PARTNER t71 ON t1.DEST_ADDRESS_ID = t71.ID LEFT JOIN RES_USERS t81 ON t1.WRITE_UID = t81.ID LEFT JOIN RES_PARTNER t91 ON t81.PARTNER_ID = t91.ID LEFT JOIN ACCOUNT_PAYMENT_TERM t101 ON t1.PAYMENT_TERM_ID = t101.ID LEFT JOIN RES_USERS t111 ON t1.CREATE_UID = t111.ID LEFT JOIN RES_PARTNER t121 ON t111.PARTNER_ID = t121.ID LEFT JOIN RES_PARTNER t131 ON t1.PARTNER_ID = t131.ID LEFT JOIN STOCK_PICKING_TYPE t141 ON t1.PICKING_TYPE_ID = t141.ID LEFT JOIN ACCOUNT_INCOTERMS t151 ON t1.INCOTERM_ID = t151.ID <![CDATA[ SELECT t1.ACCESS_TOKEN, t1.AMOUNT_TAX, t1.AMOUNT_TOTAL, t1.AMOUNT_UNTAXED, t1.COMPANY_ID, t61.NAME AS COMPANY_ID_TEXT, t1.CREATE_DATE, t1.CREATE_UID, t121.NAME AS CREATE_UID_TEXT, t1.CURRENCY_ID, t41.NAME AS CURRENCY_ID_TEXT, t1.DATE_APPROVE, t1.DATE_ORDER, t1.DATE_PLANNED, t1.DEST_ADDRESS_ID, t71.NAME AS DEST_ADDRESS_ID_TEXT, t1.FISCAL_POSITION_ID, t31.NAME AS FISCAL_POSITION_ID_TEXT, t1.GROUP_ID, t1.ID, t1.INCOTERM_ID, t151.NAME AS INCOTERM_ID_TEXT, t1.INVOICE_COUNT, t1.INVOICE_STATUS, t1.MESSAGE_MAIN_ATTACHMENT_ID, t1.NAME, t1.NOTES, t1.ORIGIN, t1.PARTNER_ID, t131.NAME AS PARTNER_ID_TEXT, t1.PARTNER_REF, t1.PAYMENT_TERM_ID, t101.NAME AS PAYMENT_TERM_ID_TEXT, t1.PICKING_COUNT, t1.PICKING_TYPE_ID, t141.NAME AS PICKING_TYPE_ID_TEXT, t1.REQUISITION_ID, t1.STATE, t1.USER_ID, t21.NAME AS USER_ID_TEXT, t1.WRITE_DATE, t1.WRITE_UID, t91.NAME AS WRITE_UID_TEXT FROM PURCHASE_ORDER t1 LEFT JOIN RES_USERS t11 ON t1.USER_ID = t11.ID LEFT JOIN RES_PARTNER t21 ON t11.PARTNER_ID = t21.ID LEFT JOIN ACCOUNT_FISCAL_POSITION t31 ON t1.FISCAL_POSITION_ID = t31.ID LEFT JOIN RES_CURRENCY t41 ON t1.CURRENCY_ID = t41.ID LEFT JOIN RES_COMPANY t51 ON t1.COMPANY_ID = t51.ID LEFT JOIN RES_PARTNER t61 ON t51.PARTNER_ID = t61.ID LEFT JOIN RES_PARTNER t71 ON t1.DEST_ADDRESS_ID = t71.ID LEFT JOIN RES_USERS t81 ON t1.WRITE_UID = t81.ID LEFT JOIN RES_PARTNER t91 ON t81.PARTNER_ID = t91.ID LEFT JOIN ACCOUNT_PAYMENT_TERM t101 ON t1.PAYMENT_TERM_ID = t101.ID LEFT JOIN RES_USERS t111 ON t1.CREATE_UID = t111.ID LEFT JOIN RES_PARTNER t121 ON t111.PARTNER_ID = t121.ID LEFT JOIN RES_PARTNER t131 ON t1.PARTNER_ID = t131.ID LEFT JOIN STOCK_PICKING_TYPE t141 ON t1.PICKING_TYPE_ID = t141.ID LEFT JOIN ACCOUNT_INCOTERMS t151 ON t1.INCOTERM_ID = t151.ID
]]> ]]>
</sql> </sql>
</mapper> </mapper>
......
...@@ -122057,6 +122057,23 @@ ...@@ -122057,6 +122057,23 @@
"data_type":"BIGINT", "data_type":"BIGINT",
"key_field":0, "key_field":0,
"major_field":0 "major_field":0
},
{
"fieldname":"REQUISITION_ID" ,
"codename":"Requisition_id",
"field_logic_name":"ID",
"entity_name":"Purchase_order",
"ref_de":"PURCHASE_REQUISITION",
"ref_field_name":"ID",
"relation_name":"DER1N_PURCHASE_ORDER_PURCHASE_REQUISITION_REQUISITION_ID",
"relation_codename":"Odoo_requisition",
"field_type":"PICKUP",
"nullable":1,
"physical_field":1,
"data_type":"BIGINT",
"data_length":20,
"key_field":0,
"major_field":0
} }
], ],
"subEntitys":[ "subEntitys":[
...@@ -122080,6 +122097,12 @@ ...@@ -122080,6 +122097,12 @@
} }
], ],
"parentEntitys":[ "parentEntitys":[
{"name":"DER1N_PURCHASE_ORDER_PURCHASE_REQUISITION_REQUISITION_ID",
"relation_type":"DER1N",
"code_name":"Odoo_requisition",
"entity_name":"PURCHASE_ORDER",
"ref_entity_name":"PURCHASE_REQUISITION"
},
{"name":"DER1N_PURCHASE_ORDER__ACCOUNT_FISCAL_POSITION__FISCAL_POSITION_ID", {"name":"DER1N_PURCHASE_ORDER__ACCOUNT_FISCAL_POSITION__FISCAL_POSITION_ID",
"relation_type":"DER1N", "relation_type":"DER1N",
"code_name":"Odoo_fiscal_position", "code_name":"Odoo_fiscal_position",
...@@ -123966,6 +123989,12 @@ ...@@ -123966,6 +123989,12 @@
} }
], ],
"subEntitys":[ "subEntitys":[
{"name":"DER1N_PURCHASE_ORDER_PURCHASE_REQUISITION_REQUISITION_ID",
"relation_type":"DER1N",
"code_name":"Odoo_requisition",
"entity_name":"PURCHASE_ORDER",
"ref_entity_name":"PURCHASE_REQUISITION"
},
{"name":"DER1N_PURCHASE_REQUISITION_LINE_PURCHASE_REQUISITION_REQUISITION_ID", {"name":"DER1N_PURCHASE_REQUISITION_LINE_PURCHASE_REQUISITION_REQUISITION_ID",
"relation_type":"DER1N", "relation_type":"DER1N",
"code_name":"Requisition", "code_name":"Requisition",
...@@ -655,6 +655,15 @@ public class Purchase_orderDTO extends DTOBase implements Serializable { ...@@ -655,6 +655,15 @@ public class Purchase_orderDTO extends DTOBase implements Serializable {
@NotNull(message = "[交货到]不允许为空!") @NotNull(message = "[交货到]不允许为空!")
private Long pickingTypeId; private Long pickingTypeId;
/**
* 属性 [REQUISITION_ID]
*
*/
@JSONField(name = "requisition_id")
@JsonProperty("requisition_id")
@JsonSerialize(using = ToStringSerializer.class)
private Long requisitionId;
/** /**
* 设置 [ACCESS_TOKEN] * 设置 [ACCESS_TOKEN]
...@@ -864,6 +873,14 @@ public class Purchase_orderDTO extends DTOBase implements Serializable { ...@@ -864,6 +873,14 @@ public class Purchase_orderDTO extends DTOBase implements Serializable {
this.modify("picking_type_id",pickingTypeId); this.modify("picking_type_id",pickingTypeId);
} }
/**
* 设置 [REQUISITION_ID]
*/
public void setRequisitionId(Long requisitionId){
this.requisitionId = requisitionId ;
this.modify("requisition_id",requisitionId);
}
} }
......
Markdown 格式
0% or
您添加了 0 到此讨论。请谨慎行事。
先完成此消息的编辑!
想要评论请 注册