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

xignzi006 发布系统代码 [Spring Boot]

上级 0b056e4a
package cn.ibizlab.businesscentral.core.extensions.service;
import cn.ibizlab.businesscentral.core.odoo_base.service.impl.Res_config_settingsServiceImpl;
import lombok.extern.slf4j.Slf4j;
import cn.ibizlab.businesscentral.core.odoo_base.domain.Res_config_settings;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;
import org.springframework.context.annotation.Primary;
import java.util.*;
/**
* 实体[配置设定] 自定义服务对象
*/
@Slf4j
@Primary
@Service("Res_config_settingsExService")
public class Res_config_settingsExService extends Res_config_settingsServiceImpl {
@Override
protected Class currentModelClass() {
return com.baomidou.mybatisplus.core.toolkit.ReflectionKit.getSuperClassGenericType(this.getClass().getSuperclass(), 1);
}
/**
* 自定义行为[Get_default]用户扩展
* @param et
* @return
*/
@Override
@Transactional
public Res_config_settings get_default(Res_config_settings et) {
return super.get_default(et);
}
}
......@@ -71,6 +71,9 @@ public class Account_fiscal_positionServiceImpl extends EBSServiceImpl<Account_f
protected cn.ibizlab.businesscentral.core.odoo_purchase.service.IPurchase_reportService purchaseReportService;
@Autowired
@Lazy
protected cn.ibizlab.businesscentral.core.odoo_base.service.IRes_supplierService resSupplierService;
@Autowired
@Lazy
protected cn.ibizlab.businesscentral.core.odoo_sale.service.ISale_orderService saleOrderService;
@Autowired
@Lazy
......
......@@ -69,6 +69,10 @@ public class res_config_settingsFallback implements res_config_settingsFeignClie
}
public Res_config_settings get_default( Long id, Res_config_settings res_config_settings){
return null;
}
public Boolean save(Res_config_settings res_config_settings){
return false;
}
......
......@@ -64,6 +64,10 @@ public interface res_config_settingsFeignClient {
Boolean checkKey(@RequestBody Res_config_settings res_config_settings);
@RequestMapping(method = RequestMethod.GET, value = "/res_config_settings/{id}/get_default")
Res_config_settings get_default(@PathVariable("id") Long id,@RequestBody Res_config_settings res_config_settings);
@RequestMapping(method = RequestMethod.POST, value = "/res_config_settings/save")
Boolean save(@RequestBody Res_config_settings res_config_settings);
......
......@@ -196,6 +196,186 @@ public class Res_supplier extends EntityMP implements Serializable {
@JSONField(name = "state_id")
@JsonProperty("state_id")
private Long stateId;
/**
* 交货方法
*/
@TableField(exist = false)
@JSONField(name = "property_delivery_carrier_id")
@JsonProperty("property_delivery_carrier_id")
@DynaProperty(res_model="res.partner",reference=cn.ibizlab.businesscentral.core.odoo_stock.service.IDelivery_carrierService.class,pickup_text = "property_delivery_carrier_name",reference_field = "name")
private Long propertyDeliveryCarrierId;
/**
* 交货方法
*/
@TableField(exist = false)
@JSONField(name = "property_delivery_carrier_name")
@JsonProperty("property_delivery_carrier_name")
private String propertyDeliveryCarrierName;
/**
* 销售付款条款
*/
@TableField(exist = false)
@JSONField(name = "property_payment_term_id")
@JsonProperty("property_payment_term_id")
@DynaProperty(res_model="res.partner",reference=cn.ibizlab.businesscentral.core.odoo_account.service.IAccount_payment_termService.class,pickup_text = "property_payment_term_name",reference_field = "name")
private Long propertyPaymentTermId;
/**
* 付款条款
*/
@TableField(exist = false)
@JSONField(name = "property_payment_term_name")
@JsonProperty("property_payment_term_name")
private String propertyPaymentTermName;
/**
* 供应商货币
*/
@TableField(exist = false)
@JSONField(name = "property_purchase_currency_id")
@JsonProperty("property_purchase_currency_id")
@DynaProperty(res_model="res.partner",reference=cn.ibizlab.businesscentral.core.odoo_base.service.IRes_currencyService.class,pickup_text = "property_purchase_currency_name",reference_field = "name")
private Long propertyPurchaseCurrencyId;
/**
* 供应商货币
*/
@TableField(exist = false)
@JSONField(name = "property_purchase_currency_name")
@JsonProperty("property_purchase_currency_name")
private String propertyPurchaseCurrencyName;
/**
* 税科目调整
*/
@TableField(exist = false)
@JSONField(name = "property_account_position_id")
@JsonProperty("property_account_position_id")
@DynaProperty(res_model="res.partner",reference=cn.ibizlab.businesscentral.core.odoo_account.service.IAccount_fiscal_positionService.class,pickup_text = "property_account_position_name",reference_field = "name")
private Long propertyAccountPositionId;
/**
* 税科目调整
*/
@TableField(exist = false)
@JSONField(name = "property_account_position_name")
@JsonProperty("property_account_position_name")
private String propertyAccountPositionName;
/**
* 客户位置
*/
@TableField(exist = false)
@JSONField(name = "property_stock_customer")
@JsonProperty("property_stock_customer")
@DynaProperty(res_model="res.partner",reference=cn.ibizlab.businesscentral.core.odoo_stock.service.IStock_locationService.class,pickup_text = "property_stock_customer_name",reference_field = "name")
private Long propertyStockCustomer;
/**
* 客户位置
*/
@TableField(exist = false)
@JSONField(name = "property_stock_customer_name")
@JsonProperty("property_stock_customer_name")
private String propertyStockCustomerName;
/**
* 供应商位置
*/
@TableField(exist = false)
@JSONField(name = "property_stock_supplier")
@JsonProperty("property_stock_supplier")
@DynaProperty(res_model="res.partner",reference=cn.ibizlab.businesscentral.core.odoo_stock.service.IStock_locationService.class,pickup_text = "property_stock_supplier_name",reference_field = "name")
private Long propertyStockSupplier;
/**
* 供应商位置
*/
@TableField(exist = false)
@JSONField(name = "property_stock_supplier_name")
@JsonProperty("property_stock_supplier_name")
private String propertyStockSupplierName;
/**
* 分包商位置
*/
@TableField(exist = false)
@JSONField(name = "property_stock_subcontractor")
@JsonProperty("property_stock_subcontractor")
@DynaProperty(res_model="res.partner",reference=cn.ibizlab.businesscentral.core.odoo_stock.service.IStock_locationService.class,pickup_text = "property_stock_subcontractor_name",reference_field = "name")
private Long propertyStockSubcontractor;
/**
* 分包商位置
*/
@TableField(exist = false)
@JSONField(name = "property_stock_subcontractor_name")
@JsonProperty("property_stock_subcontractor_name")
private String propertyStockSubcontractorName;
/**
* 销售员
*/
@DEField(name = "user_id")
@TableField(value = "user_id")
@JSONField(name = "user_id")
@JsonProperty("user_id")
private Long userId;
/**
* 销售员
*/
@TableField(exist = false)
@JSONField(name = "user_name")
@JsonProperty("user_name")
private String userName;
/**
* 价格表
*/
@TableField(exist = false)
@JSONField(name = "property_product_pricelist")
@JsonProperty("property_product_pricelist")
@DynaProperty(res_model="res.partner",reference=cn.ibizlab.businesscentral.core.odoo_product.service.IProduct_pricelistService.class,pickup_text = "property_product_pricelist_name",reference_field = "name")
private Long propertyProductPricelist;
/**
* 价格表
*/
@TableField(exist = false)
@JSONField(name = "property_product_pricelist_name")
@JsonProperty("property_product_pricelist_name")
private String propertyProductPricelistName;
/**
* ID
*/
@DEField(name = "parent_id")
@TableField(value = "parent_id")
@JSONField(name = "parent_id")
@JsonProperty("parent_id")
private Long parentId;
/**
* 公司
*/
@TableField(exist = false)
@JSONField(name = "parent_name")
@JsonProperty("parent_name")
private String parentName;
/**
* 条码
*/
@TableField(value = "barcode")
@JSONField(name = "barcode")
@JsonProperty("barcode")
private String barcode;
/**
* 内部参考
*/
@TableField(value = "ref")
@JSONField(name = "ref")
@JsonProperty("ref")
private String ref;
/**
*
*/
@JsonIgnore
@JSONField(serialize = false)
@TableField(exist = false)
private cn.ibizlab.businesscentral.core.odoo_account.domain.Account_fiscal_position odooAccountPosition;
/**
*
*/
@JsonIgnore
@JSONField(serialize = false)
@TableField(exist = false)
private cn.ibizlab.businesscentral.core.odoo_account.domain.Account_payment_term odooAccountPaymentTerm;
/**
*
......@@ -205,6 +385,22 @@ public class Res_supplier extends EntityMP implements Serializable {
@TableField(exist = false)
private cn.ibizlab.businesscentral.core.odoo_account.domain.Account_payment_term odooPurchasePaymentTerm;
/**
*
*/
@JsonIgnore
@JSONField(serialize = false)
@TableField(exist = false)
private cn.ibizlab.businesscentral.core.odoo_stock.domain.Delivery_carrier odooDeliveryCarrier;
/**
*
*/
@JsonIgnore
@JSONField(serialize = false)
@TableField(exist = false)
private cn.ibizlab.businesscentral.core.odoo_product.domain.Product_pricelist odooPricelist;
/**
*
*/
......@@ -229,6 +425,22 @@ public class Res_supplier extends EntityMP implements Serializable {
@TableField(exist = false)
private cn.ibizlab.businesscentral.core.odoo_base.domain.Res_country_state odooState;
/**
*
*/
@JsonIgnore
@JSONField(serialize = false)
@TableField(exist = false)
private cn.ibizlab.businesscentral.core.odoo_base.domain.Res_currency odooCurrency;
/**
*
*/
@JsonIgnore
@JSONField(serialize = false)
@TableField(exist = false)
private cn.ibizlab.businesscentral.core.odoo_base.domain.Res_partner odooParent;
/**
*
*/
......@@ -237,6 +449,38 @@ public class Res_supplier extends EntityMP implements Serializable {
@TableField(exist = false)
private cn.ibizlab.businesscentral.core.odoo_base.domain.Res_partner_title odooTitle;
/**
*
*/
@JsonIgnore
@JSONField(serialize = false)
@TableField(exist = false)
private cn.ibizlab.businesscentral.core.odoo_base.domain.Res_users odooUser;
/**
*
*/
@JsonIgnore
@JSONField(serialize = false)
@TableField(exist = false)
private cn.ibizlab.businesscentral.core.odoo_stock.domain.Stock_location odooCustomerLocation;
/**
*
*/
@JsonIgnore
@JSONField(serialize = false)
@TableField(exist = false)
private cn.ibizlab.businesscentral.core.odoo_stock.domain.Stock_location odooSubcontractorLocation;
/**
*
*/
@JsonIgnore
@JSONField(serialize = false)
@TableField(exist = false)
private cn.ibizlab.businesscentral.core.odoo_stock.domain.Stock_location odooVendorLocation;
/**
......@@ -335,6 +579,38 @@ public class Res_supplier extends EntityMP implements Serializable {
this.modify("state_id",stateId);
}
/**
* 设置 [销售员]
*/
public void setUserId(Long userId){
this.userId = userId ;
this.modify("user_id",userId);
}
/**
* 设置 [ID]
*/
public void setParentId(Long parentId){
this.parentId = parentId ;
this.modify("parent_id",parentId);
}
/**
* 设置 [条码]
*/
public void setBarcode(String barcode){
this.barcode = barcode ;
this.modify("barcode",barcode);
}
/**
* 设置 [内部参考]
*/
public void setRef(String ref){
this.ref = ref ;
this.modify("ref",ref);
}
@Override
public Serializable getDefaultKey(boolean gen) {
......
......@@ -153,6 +153,216 @@ public class Res_supplierSearchContext extends QueryWrapperContext<Res_supplier>
this.getSearchCond().eq("state_id", n_state_id_eq);
}
}
private Long n_property_delivery_carrier_id_eq;//[交货方法]
public void setN_property_delivery_carrier_id_eq(Long n_property_delivery_carrier_id_eq) {
this.n_property_delivery_carrier_id_eq = n_property_delivery_carrier_id_eq;
if(!ObjectUtils.isEmpty(this.n_property_delivery_carrier_id_eq)){
this.getSearchCond().eq("property_delivery_carrier_id", n_property_delivery_carrier_id_eq);
}
}
private String n_property_delivery_carrier_name_eq;//[交货方法]
public void setN_property_delivery_carrier_name_eq(String n_property_delivery_carrier_name_eq) {
this.n_property_delivery_carrier_name_eq = n_property_delivery_carrier_name_eq;
if(!ObjectUtils.isEmpty(this.n_property_delivery_carrier_name_eq)){
this.getSearchCond().eq("property_delivery_carrier_name", n_property_delivery_carrier_name_eq);
}
}
private String n_property_delivery_carrier_name_like;//[交货方法]
public void setN_property_delivery_carrier_name_like(String n_property_delivery_carrier_name_like) {
this.n_property_delivery_carrier_name_like = n_property_delivery_carrier_name_like;
if(!ObjectUtils.isEmpty(this.n_property_delivery_carrier_name_like)){
this.getSearchCond().like("property_delivery_carrier_name", n_property_delivery_carrier_name_like);
}
}
private Long n_property_payment_term_id_eq;//[销售付款条款]
public void setN_property_payment_term_id_eq(Long n_property_payment_term_id_eq) {
this.n_property_payment_term_id_eq = n_property_payment_term_id_eq;
if(!ObjectUtils.isEmpty(this.n_property_payment_term_id_eq)){
this.getSearchCond().eq("property_payment_term_id", n_property_payment_term_id_eq);
}
}
private String n_property_payment_term_name_eq;//[付款条款]
public void setN_property_payment_term_name_eq(String n_property_payment_term_name_eq) {
this.n_property_payment_term_name_eq = n_property_payment_term_name_eq;
if(!ObjectUtils.isEmpty(this.n_property_payment_term_name_eq)){
this.getSearchCond().eq("property_payment_term_name", n_property_payment_term_name_eq);
}
}
private String n_property_payment_term_name_like;//[付款条款]
public void setN_property_payment_term_name_like(String n_property_payment_term_name_like) {
this.n_property_payment_term_name_like = n_property_payment_term_name_like;
if(!ObjectUtils.isEmpty(this.n_property_payment_term_name_like)){
this.getSearchCond().like("property_payment_term_name", n_property_payment_term_name_like);
}
}
private Long n_property_purchase_currency_id_eq;//[供应商货币]
public void setN_property_purchase_currency_id_eq(Long n_property_purchase_currency_id_eq) {
this.n_property_purchase_currency_id_eq = n_property_purchase_currency_id_eq;
if(!ObjectUtils.isEmpty(this.n_property_purchase_currency_id_eq)){
this.getSearchCond().eq("property_purchase_currency_id", n_property_purchase_currency_id_eq);
}
}
private String n_property_purchase_currency_name_eq;//[供应商货币]
public void setN_property_purchase_currency_name_eq(String n_property_purchase_currency_name_eq) {
this.n_property_purchase_currency_name_eq = n_property_purchase_currency_name_eq;
if(!ObjectUtils.isEmpty(this.n_property_purchase_currency_name_eq)){
this.getSearchCond().eq("property_purchase_currency_name", n_property_purchase_currency_name_eq);
}
}
private String n_property_purchase_currency_name_like;//[供应商货币]
public void setN_property_purchase_currency_name_like(String n_property_purchase_currency_name_like) {
this.n_property_purchase_currency_name_like = n_property_purchase_currency_name_like;
if(!ObjectUtils.isEmpty(this.n_property_purchase_currency_name_like)){
this.getSearchCond().like("property_purchase_currency_name", n_property_purchase_currency_name_like);
}
}
private Long n_property_account_position_id_eq;//[税科目调整]
public void setN_property_account_position_id_eq(Long n_property_account_position_id_eq) {
this.n_property_account_position_id_eq = n_property_account_position_id_eq;
if(!ObjectUtils.isEmpty(this.n_property_account_position_id_eq)){
this.getSearchCond().eq("property_account_position_id", n_property_account_position_id_eq);
}
}
private String n_property_account_position_name_eq;//[税科目调整]
public void setN_property_account_position_name_eq(String n_property_account_position_name_eq) {
this.n_property_account_position_name_eq = n_property_account_position_name_eq;
if(!ObjectUtils.isEmpty(this.n_property_account_position_name_eq)){
this.getSearchCond().eq("property_account_position_name", n_property_account_position_name_eq);
}
}
private String n_property_account_position_name_like;//[税科目调整]
public void setN_property_account_position_name_like(String n_property_account_position_name_like) {
this.n_property_account_position_name_like = n_property_account_position_name_like;
if(!ObjectUtils.isEmpty(this.n_property_account_position_name_like)){
this.getSearchCond().like("property_account_position_name", n_property_account_position_name_like);
}
}
private Long n_property_stock_customer_eq;//[客户位置]
public void setN_property_stock_customer_eq(Long n_property_stock_customer_eq) {
this.n_property_stock_customer_eq = n_property_stock_customer_eq;
if(!ObjectUtils.isEmpty(this.n_property_stock_customer_eq)){
this.getSearchCond().eq("property_stock_customer", n_property_stock_customer_eq);
}
}
private String n_property_stock_customer_name_eq;//[客户位置]
public void setN_property_stock_customer_name_eq(String n_property_stock_customer_name_eq) {
this.n_property_stock_customer_name_eq = n_property_stock_customer_name_eq;
if(!ObjectUtils.isEmpty(this.n_property_stock_customer_name_eq)){
this.getSearchCond().eq("property_stock_customer_name", n_property_stock_customer_name_eq);
}
}
private String n_property_stock_customer_name_like;//[客户位置]
public void setN_property_stock_customer_name_like(String n_property_stock_customer_name_like) {
this.n_property_stock_customer_name_like = n_property_stock_customer_name_like;
if(!ObjectUtils.isEmpty(this.n_property_stock_customer_name_like)){
this.getSearchCond().like("property_stock_customer_name", n_property_stock_customer_name_like);
}
}
private Long n_property_stock_supplier_eq;//[供应商位置]
public void setN_property_stock_supplier_eq(Long n_property_stock_supplier_eq) {
this.n_property_stock_supplier_eq = n_property_stock_supplier_eq;
if(!ObjectUtils.isEmpty(this.n_property_stock_supplier_eq)){
this.getSearchCond().eq("property_stock_supplier", n_property_stock_supplier_eq);
}
}
private String n_property_stock_supplier_name_eq;//[供应商位置]
public void setN_property_stock_supplier_name_eq(String n_property_stock_supplier_name_eq) {
this.n_property_stock_supplier_name_eq = n_property_stock_supplier_name_eq;
if(!ObjectUtils.isEmpty(this.n_property_stock_supplier_name_eq)){
this.getSearchCond().eq("property_stock_supplier_name", n_property_stock_supplier_name_eq);
}
}
private String n_property_stock_supplier_name_like;//[供应商位置]
public void setN_property_stock_supplier_name_like(String n_property_stock_supplier_name_like) {
this.n_property_stock_supplier_name_like = n_property_stock_supplier_name_like;
if(!ObjectUtils.isEmpty(this.n_property_stock_supplier_name_like)){
this.getSearchCond().like("property_stock_supplier_name", n_property_stock_supplier_name_like);
}
}
private Long n_property_stock_subcontractor_eq;//[分包商位置]
public void setN_property_stock_subcontractor_eq(Long n_property_stock_subcontractor_eq) {
this.n_property_stock_subcontractor_eq = n_property_stock_subcontractor_eq;
if(!ObjectUtils.isEmpty(this.n_property_stock_subcontractor_eq)){
this.getSearchCond().eq("property_stock_subcontractor", n_property_stock_subcontractor_eq);
}
}
private String n_property_stock_subcontractor_name_eq;//[分包商位置]
public void setN_property_stock_subcontractor_name_eq(String n_property_stock_subcontractor_name_eq) {
this.n_property_stock_subcontractor_name_eq = n_property_stock_subcontractor_name_eq;
if(!ObjectUtils.isEmpty(this.n_property_stock_subcontractor_name_eq)){
this.getSearchCond().eq("property_stock_subcontractor_name", n_property_stock_subcontractor_name_eq);
}
}
private String n_property_stock_subcontractor_name_like;//[分包商位置]
public void setN_property_stock_subcontractor_name_like(String n_property_stock_subcontractor_name_like) {
this.n_property_stock_subcontractor_name_like = n_property_stock_subcontractor_name_like;
if(!ObjectUtils.isEmpty(this.n_property_stock_subcontractor_name_like)){
this.getSearchCond().like("property_stock_subcontractor_name", n_property_stock_subcontractor_name_like);
}
}
private Long n_user_id_eq;//[销售员]
public void setN_user_id_eq(Long n_user_id_eq) {
this.n_user_id_eq = n_user_id_eq;
if(!ObjectUtils.isEmpty(this.n_user_id_eq)){
this.getSearchCond().eq("user_id", n_user_id_eq);
}
}
private String n_user_name_eq;//[销售员]
public void setN_user_name_eq(String n_user_name_eq) {
this.n_user_name_eq = n_user_name_eq;
if(!ObjectUtils.isEmpty(this.n_user_name_eq)){
this.getSearchCond().eq("user_name", n_user_name_eq);
}
}
private String n_user_name_like;//[销售员]
public void setN_user_name_like(String n_user_name_like) {
this.n_user_name_like = n_user_name_like;
if(!ObjectUtils.isEmpty(this.n_user_name_like)){
this.getSearchCond().like("user_name", n_user_name_like);
}
}
private Long n_property_product_pricelist_eq;//[价格表]
public void setN_property_product_pricelist_eq(Long n_property_product_pricelist_eq) {
this.n_property_product_pricelist_eq = n_property_product_pricelist_eq;
if(!ObjectUtils.isEmpty(this.n_property_product_pricelist_eq)){
this.getSearchCond().eq("property_product_pricelist", n_property_product_pricelist_eq);
}
}
private String n_property_product_pricelist_name_eq;//[价格表]
public void setN_property_product_pricelist_name_eq(String n_property_product_pricelist_name_eq) {
this.n_property_product_pricelist_name_eq = n_property_product_pricelist_name_eq;
if(!ObjectUtils.isEmpty(this.n_property_product_pricelist_name_eq)){
this.getSearchCond().eq("property_product_pricelist_name", n_property_product_pricelist_name_eq);
}
}
private String n_property_product_pricelist_name_like;//[价格表]
public void setN_property_product_pricelist_name_like(String n_property_product_pricelist_name_like) {
this.n_property_product_pricelist_name_like = n_property_product_pricelist_name_like;
if(!ObjectUtils.isEmpty(this.n_property_product_pricelist_name_like)){
this.getSearchCond().like("property_product_pricelist_name", n_property_product_pricelist_name_like);
}
}
private Long n_parent_id_eq;//[ID]
public void setN_parent_id_eq(Long n_parent_id_eq) {
this.n_parent_id_eq = n_parent_id_eq;
if(!ObjectUtils.isEmpty(this.n_parent_id_eq)){
this.getSearchCond().eq("parent_id", n_parent_id_eq);
}
}
private String n_parent_name_eq;//[公司]
public void setN_parent_name_eq(String n_parent_name_eq) {
this.n_parent_name_eq = n_parent_name_eq;
if(!ObjectUtils.isEmpty(this.n_parent_name_eq)){
this.getSearchCond().eq("parent_name", n_parent_name_eq);
}
}
private String n_parent_name_like;//[公司]
public void setN_parent_name_like(String n_parent_name_like) {
this.n_parent_name_like = n_parent_name_like;
if(!ObjectUtils.isEmpty(this.n_parent_name_like)){
this.getSearchCond().like("parent_name", n_parent_name_like);
}
}
/**
* 启用快速搜索
......
......@@ -62,16 +62,36 @@ public interface Res_supplierMapper extends BaseMapper<Res_supplier>{
@Delete("${sql}")
boolean deleteBySQL(@Param("sql") String sql, @Param("et")Map param);
List<Res_supplier> selectByPropertyAccountPositionId(@Param("id") Serializable id) ;
List<Res_supplier> selectByPropertyPaymentTermId(@Param("id") Serializable id) ;
List<Res_supplier> selectByPropertySupplierPaymentTermId(@Param("id") Serializable id) ;
List<Res_supplier> selectByPropertyDeliveryCarrierId(@Param("id") Serializable id) ;
List<Res_supplier> selectByPropertyProductPricelist(@Param("id") Serializable id) ;
List<Res_supplier> selectByCompanyId(@Param("id") Serializable id) ;
List<Res_supplier> selectByCountryId(@Param("id") Serializable id) ;
List<Res_supplier> selectByStateId(@Param("id") Serializable id) ;
List<Res_supplier> selectByPropertyPurchaseCurrencyId(@Param("id") Serializable id) ;
List<Res_supplier> selectByParentId(@Param("id") Serializable id) ;
List<Res_supplier> selectByTitle(@Param("id") Serializable id) ;
List<Res_supplier> selectByUserId(@Param("id") Serializable id) ;
List<Res_supplier> selectByPropertyStockCustomer(@Param("id") Serializable id) ;
List<Res_supplier> selectByPropertyStockSubcontractor(@Param("id") Serializable id) ;
List<Res_supplier> selectByPropertyStockSupplier(@Param("id") Serializable id) ;
boolean saveRelByCategoryId(@Param("partner_id") Long partner_id, List<cn.ibizlab.businesscentral.util.domain.MultiSelectItem> res_partner_categories);
......
......@@ -34,6 +34,7 @@ public interface IRes_config_settingsService extends IService<Res_config_setting
Res_config_settings get(Long key) ;
Res_config_settings getDraft(Res_config_settings et) ;
boolean checkKey(Res_config_settings et) ;
Res_config_settings get_default(Res_config_settings et) ;
boolean save(Res_config_settings et) ;
void saveBatch(List<Res_config_settings> list) ;
Page<Res_config_settings> searchDefault(Res_config_settingsSearchContext context) ;
......
......@@ -38,16 +38,36 @@ public interface IRes_supplierService extends IService<Res_supplier>{
boolean save(Res_supplier et) ;
void saveBatch(List<Res_supplier> list) ;
Page<Res_supplier> searchDefault(Res_supplierSearchContext context) ;
List<Res_supplier> selectByPropertyAccountPositionId(Long id);
void removeByPropertyAccountPositionId(Long id);
List<Res_supplier> selectByPropertyPaymentTermId(Long id);
void removeByPropertyPaymentTermId(Long id);
List<Res_supplier> selectByPropertySupplierPaymentTermId(Long id);
void removeByPropertySupplierPaymentTermId(Long id);
List<Res_supplier> selectByPropertyDeliveryCarrierId(Long id);
void removeByPropertyDeliveryCarrierId(Long id);
List<Res_supplier> selectByPropertyProductPricelist(Long id);
void removeByPropertyProductPricelist(Long id);
List<Res_supplier> selectByCompanyId(Long id);
void removeByCompanyId(Long id);
List<Res_supplier> selectByCountryId(Long id);
void removeByCountryId(Long id);
List<Res_supplier> selectByStateId(Long id);
void removeByStateId(Long id);
List<Res_supplier> selectByPropertyPurchaseCurrencyId(Long id);
void removeByPropertyPurchaseCurrencyId(Long id);
List<Res_supplier> selectByParentId(Long id);
void removeByParentId(Long id);
List<Res_supplier> selectByTitle(Long id);
void removeByTitle(Long id);
List<Res_supplier> selectByUserId(Long id);
void removeByUserId(Long id);
List<Res_supplier> selectByPropertyStockCustomer(Long id);
void removeByPropertyStockCustomer(Long id);
List<Res_supplier> selectByPropertyStockSubcontractor(Long id);
void removeByPropertyStockSubcontractor(Long id);
List<Res_supplier> selectByPropertyStockSupplier(Long id);
void removeByPropertyStockSupplier(Long id);
/**
*自定义查询SQL
* @param sql select * from table where id =#{et.param}
......
......@@ -134,6 +134,9 @@ public class Res_companyServiceImpl extends EBSServiceImpl<Res_companyMapper, Re
protected cn.ibizlab.businesscentral.core.odoo_crm.service.ICrm_teamService crmTeamService;
@Autowired
@Lazy
protected cn.ibizlab.businesscentral.core.odoo_stock.service.IDelivery_carrierService deliveryCarrierService;
@Autowired
@Lazy
protected cn.ibizlab.businesscentral.core.odoo_digest.service.IDigest_digestService digestDigestService;
@Autowired
@Lazy
......
......@@ -176,6 +176,13 @@ public class Res_config_settingsServiceImpl extends EBSServiceImpl<Res_config_se
public boolean checkKey(Res_config_settings et) {
return (!ObjectUtils.isEmpty(et.getId()))&&(!Objects.isNull(this.getById(et.getId())));
}
@Override
@Transactional
public Res_config_settings get_default(Res_config_settings et) {
//自定义代码
return et;
}
@Override
@Transactional
public boolean save(Res_config_settings et) {
......
......@@ -158,6 +158,9 @@ public class Res_currencyServiceImpl extends EBSServiceImpl<Res_currencyMapper,
protected cn.ibizlab.businesscentral.core.odoo_base.service.IRes_partner_bankService resPartnerBankService;
@Autowired
@Lazy
protected cn.ibizlab.businesscentral.core.odoo_base.service.IRes_supplierService resSupplierService;
@Autowired
@Lazy
protected cn.ibizlab.businesscentral.core.odoo_sale.service.ISale_order_lineService saleOrderLineService;
@Autowired
@Lazy
......
......@@ -235,6 +235,9 @@ public class Res_partnerServiceImpl extends EBSServiceImpl<Res_partnerMapper, Re
protected cn.ibizlab.businesscentral.core.odoo_base.service.IRes_partnerService resPartnerService = this;
@Autowired
@Lazy
protected cn.ibizlab.businesscentral.core.odoo_base.service.IRes_supplierService resSupplierService;
@Autowired
@Lazy
protected cn.ibizlab.businesscentral.core.odoo_base.service.IRes_usersService resUsersService;
@Autowired
@Lazy
......
......@@ -65,9 +65,18 @@ public class Res_supplierServiceImpl extends EBSServiceImpl<Res_supplierMapper,
protected cn.ibizlab.businesscentral.core.odoo_base.service.IRes_supplier_res_partner_category_relService resSupplierResPartnerCategoryRelService;
@Autowired
@Lazy
protected cn.ibizlab.businesscentral.core.odoo_account.service.IAccount_fiscal_positionService accountFiscalPositionService;
@Autowired
@Lazy
protected cn.ibizlab.businesscentral.core.odoo_account.service.IAccount_payment_termService accountPaymentTermService;
@Autowired
@Lazy
protected cn.ibizlab.businesscentral.core.odoo_stock.service.IDelivery_carrierService deliveryCarrierService;
@Autowired
@Lazy
protected cn.ibizlab.businesscentral.core.odoo_product.service.IProduct_pricelistService productPricelistService;
@Autowired
@Lazy
protected cn.ibizlab.businesscentral.core.odoo_base.service.IRes_companyService resCompanyService;
@Autowired
@Lazy
......@@ -77,7 +86,19 @@ public class Res_supplierServiceImpl extends EBSServiceImpl<Res_supplierMapper,
protected cn.ibizlab.businesscentral.core.odoo_base.service.IRes_country_stateService resCountryStateService;
@Autowired
@Lazy
protected cn.ibizlab.businesscentral.core.odoo_base.service.IRes_currencyService resCurrencyService;
@Autowired
@Lazy
protected cn.ibizlab.businesscentral.core.odoo_base.service.IRes_partnerService resPartnerService;
@Autowired
@Lazy
protected cn.ibizlab.businesscentral.core.odoo_base.service.IRes_partner_titleService resPartnerTitleService;
@Autowired
@Lazy
protected cn.ibizlab.businesscentral.core.odoo_base.service.IRes_usersService resUsersService;
@Autowired
@Lazy
protected cn.ibizlab.businesscentral.core.odoo_stock.service.IStock_locationService stockLocationService;
protected int batchSize = 500;
......@@ -239,6 +260,24 @@ public class Res_supplierServiceImpl extends EBSServiceImpl<Res_supplierMapper,
}
@Override
public List<Res_supplier> selectByPropertyAccountPositionId(Long id) {
return baseMapper.selectByPropertyAccountPositionId(id);
}
@Override
public void removeByPropertyAccountPositionId(Long id) {
this.remove(new QueryWrapper<Res_supplier>().eq("property_account_position_id",id));
}
@Override
public List<Res_supplier> selectByPropertyPaymentTermId(Long id) {
return baseMapper.selectByPropertyPaymentTermId(id);
}
@Override
public void removeByPropertyPaymentTermId(Long id) {
this.remove(new QueryWrapper<Res_supplier>().eq("property_payment_term_id",id));
}
@Override
public List<Res_supplier> selectByPropertySupplierPaymentTermId(Long id) {
return baseMapper.selectByPropertySupplierPaymentTermId(id);
......@@ -248,6 +287,24 @@ public class Res_supplierServiceImpl extends EBSServiceImpl<Res_supplierMapper,
this.remove(new QueryWrapper<Res_supplier>().eq("property_supplier_payment_term_id",id));
}
@Override
public List<Res_supplier> selectByPropertyDeliveryCarrierId(Long id) {
return baseMapper.selectByPropertyDeliveryCarrierId(id);
}
@Override
public void removeByPropertyDeliveryCarrierId(Long id) {
this.remove(new QueryWrapper<Res_supplier>().eq("property_delivery_carrier_id",id));
}
@Override
public List<Res_supplier> selectByPropertyProductPricelist(Long id) {
return baseMapper.selectByPropertyProductPricelist(id);
}
@Override
public void removeByPropertyProductPricelist(Long id) {
this.remove(new QueryWrapper<Res_supplier>().eq("property_product_pricelist",id));
}
@Override
public List<Res_supplier> selectByCompanyId(Long id) {
return baseMapper.selectByCompanyId(id);
......@@ -275,6 +332,24 @@ public class Res_supplierServiceImpl extends EBSServiceImpl<Res_supplierMapper,
this.remove(new QueryWrapper<Res_supplier>().eq("state_id",id));
}
@Override
public List<Res_supplier> selectByPropertyPurchaseCurrencyId(Long id) {
return baseMapper.selectByPropertyPurchaseCurrencyId(id);
}
@Override
public void removeByPropertyPurchaseCurrencyId(Long id) {
this.remove(new QueryWrapper<Res_supplier>().eq("property_purchase_currency_id",id));
}
@Override
public List<Res_supplier> selectByParentId(Long id) {
return baseMapper.selectByParentId(id);
}
@Override
public void removeByParentId(Long id) {
this.remove(new QueryWrapper<Res_supplier>().eq("parent_id",id));
}
@Override
public List<Res_supplier> selectByTitle(Long id) {
return baseMapper.selectByTitle(id);
......@@ -284,6 +359,42 @@ public class Res_supplierServiceImpl extends EBSServiceImpl<Res_supplierMapper,
this.remove(new QueryWrapper<Res_supplier>().eq("title",id));
}
@Override
public List<Res_supplier> selectByUserId(Long id) {
return baseMapper.selectByUserId(id);
}
@Override
public void removeByUserId(Long id) {
this.remove(new QueryWrapper<Res_supplier>().eq("user_id",id));
}
@Override
public List<Res_supplier> selectByPropertyStockCustomer(Long id) {
return baseMapper.selectByPropertyStockCustomer(id);
}
@Override
public void removeByPropertyStockCustomer(Long id) {
this.remove(new QueryWrapper<Res_supplier>().eq("property_stock_customer",id));
}
@Override
public List<Res_supplier> selectByPropertyStockSubcontractor(Long id) {
return baseMapper.selectByPropertyStockSubcontractor(id);
}
@Override
public void removeByPropertyStockSubcontractor(Long id) {
this.remove(new QueryWrapper<Res_supplier>().eq("property_stock_subcontractor",id));
}
@Override
public List<Res_supplier> selectByPropertyStockSupplier(Long id) {
return baseMapper.selectByPropertyStockSupplier(id);
}
@Override
public void removeByPropertyStockSupplier(Long id) {
this.remove(new QueryWrapper<Res_supplier>().eq("property_stock_supplier",id));
}
/**
* 查询集合 数据集
......@@ -301,6 +412,26 @@ public class Res_supplierServiceImpl extends EBSServiceImpl<Res_supplierMapper,
* @param et
*/
private void fillParentData(Res_supplier et){
//实体关系[DER1N_RES_SUPPLIER_ACCOUNT_FISCAL_POSITION_PROPERTY_ACCOUNT_POSITION_ID]
if(!ObjectUtils.isEmpty(et.getPropertyAccountPositionId())){
cn.ibizlab.businesscentral.core.odoo_account.domain.Account_fiscal_position odooAccountPosition=et.getOdooAccountPosition();
if(ObjectUtils.isEmpty(odooAccountPosition)){
cn.ibizlab.businesscentral.core.odoo_account.domain.Account_fiscal_position majorEntity=accountFiscalPositionService.get(et.getPropertyAccountPositionId());
et.setOdooAccountPosition(majorEntity);
odooAccountPosition=majorEntity;
}
et.setPropertyAccountPositionName(odooAccountPosition.getName());
}
//实体关系[DER1N_RES_SUPPLIER_ACCOUNT_PAYMENT_TERM_PROPERTY_PAYMENT_TERM_ID]
if(!ObjectUtils.isEmpty(et.getPropertyPaymentTermId())){
cn.ibizlab.businesscentral.core.odoo_account.domain.Account_payment_term odooAccountPaymentTerm=et.getOdooAccountPaymentTerm();
if(ObjectUtils.isEmpty(odooAccountPaymentTerm)){
cn.ibizlab.businesscentral.core.odoo_account.domain.Account_payment_term majorEntity=accountPaymentTermService.get(et.getPropertyPaymentTermId());
et.setOdooAccountPaymentTerm(majorEntity);
odooAccountPaymentTerm=majorEntity;
}
et.setPropertyPaymentTermName(odooAccountPaymentTerm.getName());
}
//实体关系[DER1N_RES_SUPPLIER_ACCOUNT_PAYMENT_TERM_PROPERTY_SUPPLIER_PAYMENT_TERM_ID]
if(!ObjectUtils.isEmpty(et.getPropertySupplierPaymentTermId())){
cn.ibizlab.businesscentral.core.odoo_account.domain.Account_payment_term odooPurchasePaymentTerm=et.getOdooPurchasePaymentTerm();
......@@ -311,6 +442,26 @@ public class Res_supplierServiceImpl extends EBSServiceImpl<Res_supplierMapper,
}
et.setPropertySupplierPaymentTermName(odooPurchasePaymentTerm.getName());
}
//实体关系[DER1N_RES_SUPPLIER_DELIVERY_CARRIER_PROPERTY_DELIVERY_CARRIER_ID]
if(!ObjectUtils.isEmpty(et.getPropertyDeliveryCarrierId())){
cn.ibizlab.businesscentral.core.odoo_stock.domain.Delivery_carrier odooDeliveryCarrier=et.getOdooDeliveryCarrier();
if(ObjectUtils.isEmpty(odooDeliveryCarrier)){
cn.ibizlab.businesscentral.core.odoo_stock.domain.Delivery_carrier majorEntity=deliveryCarrierService.get(et.getPropertyDeliveryCarrierId());
et.setOdooDeliveryCarrier(majorEntity);
odooDeliveryCarrier=majorEntity;
}
et.setPropertyDeliveryCarrierName(odooDeliveryCarrier.getName());
}
//实体关系[DER1N_RES_SUPPLIER_PRODUCT_PRICELIST_PROPERTY_PRODUCT_PRICELIST]
if(!ObjectUtils.isEmpty(et.getPropertyProductPricelist())){
cn.ibizlab.businesscentral.core.odoo_product.domain.Product_pricelist odooPricelist=et.getOdooPricelist();
if(ObjectUtils.isEmpty(odooPricelist)){
cn.ibizlab.businesscentral.core.odoo_product.domain.Product_pricelist majorEntity=productPricelistService.get(et.getPropertyProductPricelist());
et.setOdooPricelist(majorEntity);
odooPricelist=majorEntity;
}
et.setPropertyProductPricelistName(odooPricelist.getName());
}
//实体关系[DER1N_RES_SUPPLIER_RES_COMPANY_COMPANY_ID]
if(!ObjectUtils.isEmpty(et.getCompanyId())){
cn.ibizlab.businesscentral.core.odoo_base.domain.Res_company odooCompany=et.getOdooCompany();
......@@ -341,6 +492,26 @@ public class Res_supplierServiceImpl extends EBSServiceImpl<Res_supplierMapper,
}
et.setStateIdText(odooState.getName());
}
//实体关系[DER1N_RES_SUPPLIER_RES_CURRENCY_PROPERTY_PURCHASE_CURRENCY_ID]
if(!ObjectUtils.isEmpty(et.getPropertyPurchaseCurrencyId())){
cn.ibizlab.businesscentral.core.odoo_base.domain.Res_currency odooCurrency=et.getOdooCurrency();
if(ObjectUtils.isEmpty(odooCurrency)){
cn.ibizlab.businesscentral.core.odoo_base.domain.Res_currency majorEntity=resCurrencyService.get(et.getPropertyPurchaseCurrencyId());
et.setOdooCurrency(majorEntity);
odooCurrency=majorEntity;
}
et.setPropertyPurchaseCurrencyName(odooCurrency.getName());
}
//实体关系[DER1N_RES_SUPPLIER_RES_PARTNER_PARENT_ID]
if(!ObjectUtils.isEmpty(et.getParentId())){
cn.ibizlab.businesscentral.core.odoo_base.domain.Res_partner odooParent=et.getOdooParent();
if(ObjectUtils.isEmpty(odooParent)){
cn.ibizlab.businesscentral.core.odoo_base.domain.Res_partner majorEntity=resPartnerService.get(et.getParentId());
et.setOdooParent(majorEntity);
odooParent=majorEntity;
}
et.setParentName(odooParent.getName());
}
//实体关系[DER1N_RES_SUPPLIER_RES_PARTNER_TITLE_TITLE]
if(!ObjectUtils.isEmpty(et.getTitle())){
cn.ibizlab.businesscentral.core.odoo_base.domain.Res_partner_title odooTitle=et.getOdooTitle();
......@@ -351,6 +522,46 @@ public class Res_supplierServiceImpl extends EBSServiceImpl<Res_supplierMapper,
}
et.setTitleText(odooTitle.getName());
}
//实体关系[DER1N_RES_SUPPLIER_RES_USERS_USER_ID]
if(!ObjectUtils.isEmpty(et.getUserId())){
cn.ibizlab.businesscentral.core.odoo_base.domain.Res_users odooUser=et.getOdooUser();
if(ObjectUtils.isEmpty(odooUser)){
cn.ibizlab.businesscentral.core.odoo_base.domain.Res_users majorEntity=resUsersService.get(et.getUserId());
et.setOdooUser(majorEntity);
odooUser=majorEntity;
}
et.setUserName(odooUser.getName());
}
//实体关系[DER1N_RES_SUPPLIER_STOCK_LOCATION_PROPERTY_STOCK_CUSTOMER]
if(!ObjectUtils.isEmpty(et.getPropertyStockCustomer())){
cn.ibizlab.businesscentral.core.odoo_stock.domain.Stock_location odooCustomerLocation=et.getOdooCustomerLocation();
if(ObjectUtils.isEmpty(odooCustomerLocation)){
cn.ibizlab.businesscentral.core.odoo_stock.domain.Stock_location majorEntity=stockLocationService.get(et.getPropertyStockCustomer());
et.setOdooCustomerLocation(majorEntity);
odooCustomerLocation=majorEntity;
}
et.setPropertyStockCustomerName(odooCustomerLocation.getName());
}
//实体关系[DER1N_RES_SUPPLIER_STOCK_LOCATION_PROPERTY_STOCK_SUBCONTRACTOR]
if(!ObjectUtils.isEmpty(et.getPropertyStockSubcontractor())){
cn.ibizlab.businesscentral.core.odoo_stock.domain.Stock_location odooSubcontractorLocation=et.getOdooSubcontractorLocation();
if(ObjectUtils.isEmpty(odooSubcontractorLocation)){
cn.ibizlab.businesscentral.core.odoo_stock.domain.Stock_location majorEntity=stockLocationService.get(et.getPropertyStockSubcontractor());
et.setOdooSubcontractorLocation(majorEntity);
odooSubcontractorLocation=majorEntity;
}
et.setPropertyStockSubcontractorName(odooSubcontractorLocation.getName());
}
//实体关系[DER1N_RES_SUPPLIER_STOCK_LOCATION_PROPERTY_STOCK_SUPPLIER]
if(!ObjectUtils.isEmpty(et.getPropertyStockSupplier())){
cn.ibizlab.businesscentral.core.odoo_stock.domain.Stock_location odooVendorLocation=et.getOdooVendorLocation();
if(ObjectUtils.isEmpty(odooVendorLocation)){
cn.ibizlab.businesscentral.core.odoo_stock.domain.Stock_location majorEntity=stockLocationService.get(et.getPropertyStockSupplier());
et.setOdooVendorLocation(majorEntity);
odooVendorLocation=majorEntity;
}
et.setPropertyStockSupplierName(odooVendorLocation.getName());
}
}
......
......@@ -374,6 +374,9 @@ public class Res_usersServiceImpl extends EBSServiceImpl<Res_usersMapper, Res_us
protected cn.ibizlab.businesscentral.core.odoo_crm.service.ICrm_teamService crmTeamService;
@Autowired
@Lazy
protected cn.ibizlab.businesscentral.core.odoo_stock.service.IDelivery_carrierService deliveryCarrierService;
@Autowired
@Lazy
protected cn.ibizlab.businesscentral.core.odoo_digest.service.IDigest_digestService digestDigestService;
@Autowired
@Lazy
......@@ -983,6 +986,9 @@ public class Res_usersServiceImpl extends EBSServiceImpl<Res_usersMapper, Res_us
protected cn.ibizlab.businesscentral.core.odoo_base.service.IRes_partnerService resPartnerService;
@Autowired
@Lazy
protected cn.ibizlab.businesscentral.core.odoo_base.service.IRes_supplierService resSupplierService;
@Autowired
@Lazy
protected cn.ibizlab.businesscentral.core.odoo_base.service.IRes_users_logService resUsersLogService;
protected cn.ibizlab.businesscentral.core.odoo_base.service.IRes_usersService resUsersService = this;
......
......@@ -139,7 +139,7 @@ public class Hr_contract extends EntityMP implements Serializable {
@TableField(value = "wage")
@JSONField(name = "wage")
@JsonProperty("wage")
private BigDecimal wage;
private Double wage;
/**
* 开始日期
*/
......@@ -533,7 +533,7 @@ public class Hr_contract extends EntityMP implements Serializable {
/**
* 设置 [工资]
*/
public void setWage(BigDecimal wage){
public void setWage(Double wage){
this.wage = wage ;
this.modify("wage",wage);
}
......
......@@ -62,6 +62,9 @@ public class Product_pricelistServiceImpl extends EBSServiceImpl<Product_priceli
protected cn.ibizlab.businesscentral.core.odoo_repair.service.IRepair_orderService repairOrderService;
@Autowired
@Lazy
protected cn.ibizlab.businesscentral.core.odoo_base.service.IRes_supplierService resSupplierService;
@Autowired
@Lazy
protected cn.ibizlab.businesscentral.core.odoo_sale.service.ISale_orderService saleOrderService;
@Autowired
@Lazy
......
......@@ -65,6 +65,9 @@ public class Product_productServiceImpl extends EBSServiceImpl<Product_productMa
protected cn.ibizlab.businesscentral.core.odoo_account.service.IAccount_move_lineService accountMoveLineService;
@Autowired
@Lazy
protected cn.ibizlab.businesscentral.core.odoo_stock.service.IDelivery_carrierService deliveryCarrierService;
@Autowired
@Lazy
protected cn.ibizlab.businesscentral.core.odoo_event.service.IEvent_event_ticketService eventEventTicketService;
@Autowired
@Lazy
......
package cn.ibizlab.businesscentral.core.odoo_stock.domain;
import java.sql.Timestamp;
import java.util.ArrayList;
import java.util.List;
import java.util.Map;
import java.math.BigInteger;
import java.util.HashMap;
import java.math.BigDecimal;
import java.text.SimpleDateFormat;
import com.alibaba.fastjson.annotation.JSONField;
import com.fasterxml.jackson.annotation.JsonIgnore;
import com.fasterxml.jackson.annotation.JsonProperty;
import com.fasterxml.jackson.annotation.JsonFormat;
import org.springframework.util.ObjectUtils;
import org.springframework.util.DigestUtils;
import cn.ibizlab.businesscentral.util.domain.EntityBase;
import cn.ibizlab.businesscentral.util.annotation.DEField;
import cn.ibizlab.businesscentral.util.annotation.DynaProperty;
import cn.ibizlab.businesscentral.util.enums.DEPredefinedFieldType;
import cn.ibizlab.businesscentral.util.enums.DEFieldDefaultValueType;
import cn.ibizlab.businesscentral.util.helper.DataObject;
import java.io.Serializable;
import lombok.*;
import org.springframework.data.annotation.Transient;
import cn.ibizlab.businesscentral.util.annotation.Audit;
import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
import com.baomidou.mybatisplus.annotation.*;
import cn.ibizlab.businesscentral.util.domain.EntityMP;
import com.baomidou.mybatisplus.core.toolkit.IdWorker;
/**
* 实体[送货方式]
*/
@Getter
@Setter
@NoArgsConstructor
@JsonIgnoreProperties(value = "handler")
@TableName(value = "DELIVERY_CARRIER",resultMap = "Delivery_carrierResultMap")
public class Delivery_carrier extends EntityMP implements Serializable {
private static final long serialVersionUID = 1L;
/**
* ID
*/
@DEField(isKeyField=true)
@TableId(value= "id",type=IdType.AUTO)
@JSONField(name = "id")
@JsonProperty("id")
private Long id;
/**
* 名称
*/
@TableField(value = "name")
@JSONField(name = "name")
@JsonProperty("name")
private String name;
/**
* 有效
*/
@TableField(value = "active")
@JSONField(name = "active")
@JsonProperty("active")
private Boolean active;
/**
* 序号
*/
@TableField(value = "sequence")
@JSONField(name = "sequence")
@JsonProperty("sequence")
private Integer sequence;
/**
* 集成级别
*/
@DEField(name = "integration_level")
@TableField(value = "integration_level")
@JSONField(name = "integration_level")
@JsonProperty("integration_level")
private String integrationLevel;
/**
* 生产环境
*/
@DEField(name = "prod_environment")
@TableField(value = "prod_environment")
@JSONField(name = "prod_environment")
@JsonProperty("prod_environment")
private Boolean prodEnvironment;
/**
* 调试记录
*/
@DEField(name = "debug_logging")
@TableField(value = "debug_logging")
@JSONField(name = "debug_logging")
@JsonProperty("debug_logging")
private Boolean debugLogging;
/**
* ID
*/
@DEField(name = "company_id")
@TableField(value = "company_id")
@JSONField(name = "company_id")
@JsonProperty("company_id")
private Long companyId;
/**
* ID
*/
@DEField(name = "product_id")
@TableField(value = "product_id")
@JSONField(name = "product_id")
@JsonProperty("product_id")
private Long productId;
/**
* 公司名称
*/
@TableField(exist = false)
@JSONField(name = "company_name")
@JsonProperty("company_name")
private String companyName;
/**
* 名称
*/
@TableField(exist = false)
@JSONField(name = "product_name")
@JsonProperty("product_name")
private String productName;
/**
* 发票原则
*/
@DEField(name = "invoice_policy")
@TableField(value = "invoice_policy")
@JSONField(name = "invoice_policy")
@JsonProperty("invoice_policy")
private String invoicePolicy;
/**
* 邮编从
*/
@DEField(name = "zip_from")
@TableField(value = "zip_from")
@JSONField(name = "zip_from")
@JsonProperty("zip_from")
private String zipFrom;
/**
* 邮编到
*/
@DEField(name = "zip_to")
@TableField(value = "zip_to")
@JSONField(name = "zip_to")
@JsonProperty("zip_to")
private String zipTo;
/**
* 利润率
*/
@TableField(value = "margin")
@JSONField(name = "margin")
@JsonProperty("margin")
private Double margin;
/**
* 如果订货量大则免费
*/
@DEField(name = "free_over")
@TableField(value = "free_over")
@JSONField(name = "free_over")
@JsonProperty("free_over")
private Boolean freeOver;
/**
* 金额
*/
@TableField(value = "amount")
@JSONField(name = "amount")
@JsonProperty("amount")
private Double amount;
/**
* 交易退货标签
*/
@DEField(name = "return_label_on_delivery")
@TableField(value = "return_label_on_delivery")
@JSONField(name = "return_label_on_delivery")
@JsonProperty("return_label_on_delivery")
private Boolean returnLabelOnDelivery;
/**
* 从门户获取返回标签
*/
@DEField(name = "get_return_label_from_portal")
@TableField(value = "get_return_label_from_portal")
@JSONField(name = "get_return_label_from_portal")
@JsonProperty("get_return_label_from_portal")
private Boolean getReturnLabelFromPortal;
/**
* 固定价格
*/
@DEField(name = "fixed_price")
@TableField(value = "fixed_price")
@JSONField(name = "fixed_price")
@JsonProperty("fixed_price")
private Double fixedPrice;
/**
* 供应商
*/
@DEField(name = "delivery_type")
@TableField(value = "delivery_type")
@JSONField(name = "delivery_type")
@JsonProperty("delivery_type")
private String deliveryType;
/**
* 创建时间
*/
@DEField(name = "create_date")
@TableField(value = "create_date")
@JsonFormat(pattern="yyyy-MM-dd HH:mm:ss", locale = "zh" , timezone="GMT+8")
@JSONField(name = "create_date" , format="yyyy-MM-dd HH:mm:ss")
@JsonProperty("create_date")
private Timestamp createDate;
/**
* 最后更新时间
*/
@DEField(name = "write_date")
@TableField(value = "write_date")
@JsonFormat(pattern="yyyy-MM-dd HH:mm:ss", locale = "zh" , timezone="GMT+8")
@JSONField(name = "write_date" , format="yyyy-MM-dd HH:mm:ss")
@JsonProperty("write_date")
private Timestamp writeDate;
/**
* 是否公开
*/
@DEField(name = "is_published")
@TableField(value = "is_published")
@JSONField(name = "is_published")
@JsonProperty("is_published")
private Boolean isPublished;
/**
* ID
*/
@DEField(name = "write_uid")
@TableField(value = "write_uid")
@JSONField(name = "write_uid")
@JsonProperty("write_uid")
private Long writeUid;
/**
* ID
*/
@DEField(name = "create_uid")
@TableField(value = "create_uid")
@JSONField(name = "create_uid")
@JsonProperty("create_uid")
private Long createUid;
/**
* 名称
*/
@TableField(exist = false)
@JSONField(name = "write_uname")
@JsonProperty("write_uname")
private String writeUname;
/**
* 名称
*/
@TableField(exist = false)
@JSONField(name = "create_uname")
@JsonProperty("create_uname")
private String createUname;
/**
*
*/
@JsonIgnore
@JSONField(serialize = false)
@TableField(exist = false)
private cn.ibizlab.businesscentral.core.odoo_product.domain.Product_product odooProduct;
/**
*
*/
@JsonIgnore
@JSONField(serialize = false)
@TableField(exist = false)
private cn.ibizlab.businesscentral.core.odoo_base.domain.Res_company odooCompany;
/**
*
*/
@JsonIgnore
@JSONField(serialize = false)
@TableField(exist = false)
private cn.ibizlab.businesscentral.core.odoo_base.domain.Res_users odooCreate;
/**
*
*/
@JsonIgnore
@JSONField(serialize = false)
@TableField(exist = false)
private cn.ibizlab.businesscentral.core.odoo_base.domain.Res_users odooWrite;
/**
* 设置 [名称]
*/
public void setName(String name){
this.name = name ;
this.modify("name",name);
}
/**
* 设置 [有效]
*/
public void setActive(Boolean active){
this.active = active ;
this.modify("active",active);
}
/**
* 设置 [序号]
*/
public void setSequence(Integer sequence){
this.sequence = sequence ;
this.modify("sequence",sequence);
}
/**
* 设置 [集成级别]
*/
public void setIntegrationLevel(String integrationLevel){
this.integrationLevel = integrationLevel ;
this.modify("integration_level",integrationLevel);
}
/**
* 设置 [生产环境]
*/
public void setProdEnvironment(Boolean prodEnvironment){
this.prodEnvironment = prodEnvironment ;
this.modify("prod_environment",prodEnvironment);
}
/**
* 设置 [调试记录]
*/
public void setDebugLogging(Boolean debugLogging){
this.debugLogging = debugLogging ;
this.modify("debug_logging",debugLogging);
}
/**
* 设置 [ID]
*/
public void setCompanyId(Long companyId){
this.companyId = companyId ;
this.modify("company_id",companyId);
}
/**
* 设置 [ID]
*/
public void setProductId(Long productId){
this.productId = productId ;
this.modify("product_id",productId);
}
/**
* 设置 [发票原则]
*/
public void setInvoicePolicy(String invoicePolicy){
this.invoicePolicy = invoicePolicy ;
this.modify("invoice_policy",invoicePolicy);
}
/**
* 设置 [邮编从]
*/
public void setZipFrom(String zipFrom){
this.zipFrom = zipFrom ;
this.modify("zip_from",zipFrom);
}
/**
* 设置 [邮编到]
*/
public void setZipTo(String zipTo){
this.zipTo = zipTo ;
this.modify("zip_to",zipTo);
}
/**
* 设置 [利润率]
*/
public void setMargin(Double margin){
this.margin = margin ;
this.modify("margin",margin);
}
/**
* 设置 [如果订货量大则免费]
*/
public void setFreeOver(Boolean freeOver){
this.freeOver = freeOver ;
this.modify("free_over",freeOver);
}
/**
* 设置 [金额]
*/
public void setAmount(Double amount){
this.amount = amount ;
this.modify("amount",amount);
}
/**
* 设置 [交易退货标签]
*/
public void setReturnLabelOnDelivery(Boolean returnLabelOnDelivery){
this.returnLabelOnDelivery = returnLabelOnDelivery ;
this.modify("return_label_on_delivery",returnLabelOnDelivery);
}
/**
* 设置 [从门户获取返回标签]
*/
public void setGetReturnLabelFromPortal(Boolean getReturnLabelFromPortal){
this.getReturnLabelFromPortal = getReturnLabelFromPortal ;
this.modify("get_return_label_from_portal",getReturnLabelFromPortal);
}
/**
* 设置 [固定价格]
*/
public void setFixedPrice(Double fixedPrice){
this.fixedPrice = fixedPrice ;
this.modify("fixed_price",fixedPrice);
}
/**
* 设置 [供应商]
*/
public void setDeliveryType(String deliveryType){
this.deliveryType = deliveryType ;
this.modify("delivery_type",deliveryType);
}
/**
* 设置 [创建时间]
*/
public void setCreateDate(Timestamp createDate){
this.createDate = createDate ;
this.modify("create_date",createDate);
}
/**
* 格式化日期 [创建时间]
*/
public String formatCreateDate(){
if (this.createDate == null) {
return null;
}
SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
return sdf.format(createDate);
}
/**
* 设置 [最后更新时间]
*/
public void setWriteDate(Timestamp writeDate){
this.writeDate = writeDate ;
this.modify("write_date",writeDate);
}
/**
* 格式化日期 [最后更新时间]
*/
public String formatWriteDate(){
if (this.writeDate == null) {
return null;
}
SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
return sdf.format(writeDate);
}
/**
* 设置 [是否公开]
*/
public void setIsPublished(Boolean isPublished){
this.isPublished = isPublished ;
this.modify("is_published",isPublished);
}
/**
* 设置 [ID]
*/
public void setWriteUid(Long writeUid){
this.writeUid = writeUid ;
this.modify("write_uid",writeUid);
}
/**
* 设置 [ID]
*/
public void setCreateUid(Long createUid){
this.createUid = createUid ;
this.modify("create_uid",createUid);
}
@Override
public Serializable getDefaultKey(boolean gen) {
return IdWorker.getId();
}
/**
* 复制当前对象数据到目标对象(粘贴重置)
* @param targetEntity 目标数据对象
* @param bIncEmpty 是否包括空值
* @param <T>
* @return
*/
@Override
public <T> T copyTo(T targetEntity, boolean bIncEmpty) {
this.reset("id");
return super.copyTo(targetEntity,bIncEmpty);
}
}
package cn.ibizlab.businesscentral.core.odoo_stock.filter;
import java.math.BigDecimal;
import java.math.BigInteger;
import java.sql.Timestamp;
import java.util.ArrayList;
import java.util.List;
import java.util.Map;
import java.util.HashMap;
import lombok.*;
import lombok.extern.slf4j.Slf4j;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.alibaba.fastjson.annotation.JSONField;
import org.springframework.util.ObjectUtils;
import org.springframework.util.StringUtils;
import cn.ibizlab.businesscentral.util.filter.QueryWrapperContext;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import cn.ibizlab.businesscentral.core.odoo_stock.domain.Delivery_carrier;
/**
* 关系型数据实体[Delivery_carrier] 查询条件对象
*/
@Slf4j
@Data
public class Delivery_carrierSearchContext extends QueryWrapperContext<Delivery_carrier> {
private String n_name_like;//[名称]
public void setN_name_like(String n_name_like) {
this.n_name_like = n_name_like;
if(!ObjectUtils.isEmpty(this.n_name_like)){
this.getSearchCond().like("name", n_name_like);
}
}
private String n_integration_level_eq;//[集成级别]
public void setN_integration_level_eq(String n_integration_level_eq) {
this.n_integration_level_eq = n_integration_level_eq;
if(!ObjectUtils.isEmpty(this.n_integration_level_eq)){
this.getSearchCond().eq("integration_level", n_integration_level_eq);
}
}
private Long n_company_id_eq;//[ID]
public void setN_company_id_eq(Long n_company_id_eq) {
this.n_company_id_eq = n_company_id_eq;
if(!ObjectUtils.isEmpty(this.n_company_id_eq)){
this.getSearchCond().eq("company_id", n_company_id_eq);
}
}
private Long n_product_id_eq;//[ID]
public void setN_product_id_eq(Long n_product_id_eq) {
this.n_product_id_eq = n_product_id_eq;
if(!ObjectUtils.isEmpty(this.n_product_id_eq)){
this.getSearchCond().eq("product_id", n_product_id_eq);
}
}
private String n_company_name_eq;//[公司名称]
public void setN_company_name_eq(String n_company_name_eq) {
this.n_company_name_eq = n_company_name_eq;
if(!ObjectUtils.isEmpty(this.n_company_name_eq)){
this.getSearchCond().eq("company_name", n_company_name_eq);
}
}
private String n_company_name_like;//[公司名称]
public void setN_company_name_like(String n_company_name_like) {
this.n_company_name_like = n_company_name_like;
if(!ObjectUtils.isEmpty(this.n_company_name_like)){
this.getSearchCond().like("company_name", n_company_name_like);
}
}
private String n_product_name_eq;//[名称]
public void setN_product_name_eq(String n_product_name_eq) {
this.n_product_name_eq = n_product_name_eq;
if(!ObjectUtils.isEmpty(this.n_product_name_eq)){
this.getSearchCond().eq("product_name", n_product_name_eq);
}
}
private String n_product_name_like;//[名称]
public void setN_product_name_like(String n_product_name_like) {
this.n_product_name_like = n_product_name_like;
if(!ObjectUtils.isEmpty(this.n_product_name_like)){
this.getSearchCond().like("product_name", n_product_name_like);
}
}
private String n_invoice_policy_eq;//[发票原则]
public void setN_invoice_policy_eq(String n_invoice_policy_eq) {
this.n_invoice_policy_eq = n_invoice_policy_eq;
if(!ObjectUtils.isEmpty(this.n_invoice_policy_eq)){
this.getSearchCond().eq("invoice_policy", n_invoice_policy_eq);
}
}
private String n_delivery_type_eq;//[供应商]
public void setN_delivery_type_eq(String n_delivery_type_eq) {
this.n_delivery_type_eq = n_delivery_type_eq;
if(!ObjectUtils.isEmpty(this.n_delivery_type_eq)){
this.getSearchCond().eq("delivery_type", n_delivery_type_eq);
}
}
private Long n_write_uid_eq;//[ID]
public void setN_write_uid_eq(Long n_write_uid_eq) {
this.n_write_uid_eq = n_write_uid_eq;
if(!ObjectUtils.isEmpty(this.n_write_uid_eq)){
this.getSearchCond().eq("write_uid", n_write_uid_eq);
}
}
private Long n_create_uid_eq;//[ID]
public void setN_create_uid_eq(Long n_create_uid_eq) {
this.n_create_uid_eq = n_create_uid_eq;
if(!ObjectUtils.isEmpty(this.n_create_uid_eq)){
this.getSearchCond().eq("create_uid", n_create_uid_eq);
}
}
private String n_write_uname_eq;//[名称]
public void setN_write_uname_eq(String n_write_uname_eq) {
this.n_write_uname_eq = n_write_uname_eq;
if(!ObjectUtils.isEmpty(this.n_write_uname_eq)){
this.getSearchCond().eq("write_uname", n_write_uname_eq);
}
}
private String n_write_uname_like;//[名称]
public void setN_write_uname_like(String n_write_uname_like) {
this.n_write_uname_like = n_write_uname_like;
if(!ObjectUtils.isEmpty(this.n_write_uname_like)){
this.getSearchCond().like("write_uname", n_write_uname_like);
}
}
private String n_create_uname_eq;//[名称]
public void setN_create_uname_eq(String n_create_uname_eq) {
this.n_create_uname_eq = n_create_uname_eq;
if(!ObjectUtils.isEmpty(this.n_create_uname_eq)){
this.getSearchCond().eq("create_uname", n_create_uname_eq);
}
}
private String n_create_uname_like;//[名称]
public void setN_create_uname_like(String n_create_uname_like) {
this.n_create_uname_like = n_create_uname_like;
if(!ObjectUtils.isEmpty(this.n_create_uname_like)){
this.getSearchCond().like("create_uname", n_create_uname_like);
}
}
/**
* 启用快速搜索
*/
public void setQuery(String query)
{
this.query=query;
if(!StringUtils.isEmpty(query)){
this.getSearchCond().and( wrapper ->
wrapper.like("name", query)
);
}
}
}
package cn.ibizlab.businesscentral.core.odoo_stock.mapper;
import java.util.List;
import org.apache.ibatis.annotations.*;
import java.util.Map;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.core.conditions.Wrapper;
import java.util.HashMap;
import org.apache.ibatis.annotations.Select;
import cn.ibizlab.businesscentral.core.odoo_stock.domain.Delivery_carrier;
import cn.ibizlab.businesscentral.core.odoo_stock.filter.Delivery_carrierSearchContext;
import org.springframework.cache.annotation.CacheEvict;
import org.springframework.cache.annotation.Cacheable;
import java.io.Serializable;
import com.baomidou.mybatisplus.core.toolkit.Constants;
import com.alibaba.fastjson.JSONObject;
public interface Delivery_carrierMapper extends BaseMapper<Delivery_carrier>{
Page<Delivery_carrier> searchDefault(IPage page, @Param("srf") Delivery_carrierSearchContext context, @Param("ew") Wrapper<Delivery_carrier> wrapper) ;
@Override
Delivery_carrier selectById(Serializable id);
@Override
int insert(Delivery_carrier entity);
@Override
int updateById(@Param(Constants.ENTITY) Delivery_carrier entity);
@Override
int update(@Param(Constants.ENTITY) Delivery_carrier entity, @Param("ew") Wrapper<Delivery_carrier> updateWrapper);
@Override
int deleteById(Serializable id);
/**
* 自定义查询SQL
* @param sql
* @return
*/
@Select("${sql}")
List<JSONObject> selectBySQL(@Param("sql") String sql, @Param("et")Map param);
/**
* 自定义更新SQL
* @param sql
* @return
*/
@Update("${sql}")
boolean updateBySQL(@Param("sql") String sql, @Param("et")Map param);
/**
* 自定义插入SQL
* @param sql
* @return
*/
@Insert("${sql}")
boolean insertBySQL(@Param("sql") String sql, @Param("et")Map param);
/**
* 自定义删除SQL
* @param sql
* @return
*/
@Delete("${sql}")
boolean deleteBySQL(@Param("sql") String sql, @Param("et")Map param);
List<Delivery_carrier> selectByProductId(@Param("id") Serializable id) ;
List<Delivery_carrier> selectByCompanyId(@Param("id") Serializable id) ;
List<Delivery_carrier> selectByCreateUid(@Param("id") Serializable id) ;
List<Delivery_carrier> selectByWriteUid(@Param("id") Serializable id) ;
}
package cn.ibizlab.businesscentral.core.odoo_stock.service;
import java.io.Serializable;
import java.sql.Timestamp;
import java.util.ArrayList;
import java.util.List;
import java.util.Map;
import java.util.HashMap;
import java.util.Collection;
import java.math.BigInteger;
import org.springframework.data.domain.Page;
import org.springframework.data.domain.Pageable;
import org.springframework.scheduling.annotation.Async;
import com.alibaba.fastjson.JSONObject;
import org.springframework.cache.annotation.CacheEvict;
import cn.ibizlab.businesscentral.core.odoo_stock.domain.Delivery_carrier;
import cn.ibizlab.businesscentral.core.odoo_stock.filter.Delivery_carrierSearchContext;
import com.baomidou.mybatisplus.extension.service.IService;
/**
* 实体[Delivery_carrier] 服务对象接口
*/
public interface IDelivery_carrierService extends IService<Delivery_carrier>{
boolean create(Delivery_carrier et) ;
void createBatch(List<Delivery_carrier> list) ;
boolean update(Delivery_carrier et) ;
void updateBatch(List<Delivery_carrier> list) ;
boolean remove(Long key) ;
void removeBatch(Collection<Long> idList) ;
Delivery_carrier get(Long key) ;
Delivery_carrier getDraft(Delivery_carrier et) ;
boolean checkKey(Delivery_carrier et) ;
boolean save(Delivery_carrier et) ;
void saveBatch(List<Delivery_carrier> list) ;
Page<Delivery_carrier> searchDefault(Delivery_carrierSearchContext context) ;
List<Delivery_carrier> selectByProductId(Long id);
void removeByProductId(Long id);
List<Delivery_carrier> selectByCompanyId(Long id);
void removeByCompanyId(Long id);
List<Delivery_carrier> selectByCreateUid(Long id);
void removeByCreateUid(Long id);
List<Delivery_carrier> selectByWriteUid(Long id);
void removeByWriteUid(Long id);
/**
*自定义查询SQL
* @param sql select * from table where id =#{et.param}
* @param param 参数列表 param.put("param","1");
* @return select * from table where id = '1'
*/
List<JSONObject> select(String sql, Map param);
/**
*自定义SQL
* @param sql update table set name ='test' where id =#{et.param}
* @param param 参数列表 param.put("param","1");
* @return update table set name ='test' where id = '1'
*/
boolean execute(String sql, Map param);
}
package cn.ibizlab.businesscentral.core.odoo_stock.service.impl;
import java.io.Serializable;
import java.util.ArrayList;
import java.util.List;
import java.util.Set;
import java.util.Map;
import java.util.HashSet;
import java.util.HashMap;
import java.util.Collection;
import java.util.Objects;
import java.util.Optional;
import java.math.BigInteger;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.aop.framework.AopContext;
import org.springframework.cglib.beans.BeanCopier;
import org.springframework.stereotype.Service;
import org.springframework.data.domain.Page;
import org.springframework.data.domain.PageImpl;
import org.springframework.data.domain.Pageable;
import org.springframework.util.ObjectUtils;
import org.springframework.beans.factory.annotation.Value;
import cn.ibizlab.businesscentral.util.errors.BadRequestAlertException;
import org.springframework.transaction.annotation.Transactional;
import org.springframework.context.annotation.Lazy;
import cn.ibizlab.businesscentral.core.odoo_stock.domain.Delivery_carrier;
import cn.ibizlab.businesscentral.core.odoo_stock.filter.Delivery_carrierSearchContext;
import cn.ibizlab.businesscentral.core.odoo_stock.service.IDelivery_carrierService;
import cn.ibizlab.businesscentral.util.helper.CachedBeanCopier;
import cn.ibizlab.businesscentral.util.helper.DEFieldCacheMap;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import cn.ibizlab.businesscentral.core.util.helper.EBSServiceImpl;
import cn.ibizlab.businesscentral.core.odoo_stock.mapper.Delivery_carrierMapper;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.core.conditions.update.UpdateWrapper;
import com.baomidou.mybatisplus.core.conditions.Wrapper;
import com.alibaba.fastjson.JSONObject;
import org.springframework.util.StringUtils;
/**
* 实体[送货方式] 服务对象接口实现
*/
@Slf4j
@Service("Delivery_carrierServiceImpl")
public class Delivery_carrierServiceImpl extends EBSServiceImpl<Delivery_carrierMapper, Delivery_carrier> implements IDelivery_carrierService {
@Autowired
@Lazy
protected cn.ibizlab.businesscentral.core.odoo_base.service.IRes_supplierService resSupplierService;
@Autowired
@Lazy
protected cn.ibizlab.businesscentral.core.odoo_product.service.IProduct_productService productProductService;
@Autowired
@Lazy
protected cn.ibizlab.businesscentral.core.odoo_base.service.IRes_companyService resCompanyService;
@Autowired
@Lazy
protected cn.ibizlab.businesscentral.core.odoo_base.service.IRes_usersService resUsersService;
protected int batchSize = 500;
public String getIrModel(){
return "delivery.carrier" ;
}
private boolean messageinfo = false ;
public void setMessageInfo(boolean messageinfo){
this.messageinfo = messageinfo ;
}
@Override
@Transactional
public boolean create(Delivery_carrier et) {
boolean mail_create_nosubscribe = et.get("mail_create_nosubscribe") != null;
boolean mail_create_nolog = et.get("mail_create_nolog") != null;
boolean mail_notrack = et.get("mail_notrack") != null;
fillParentData(et);
if(!this.retBool(this.baseMapper.insert(et)))
return false;
CachedBeanCopier.copy((AopContext.currentProxy() != null ? (IDelivery_carrierService)AopContext.currentProxy() : this).get(et.getId()),et);
if (messageinfo && !mail_create_nosubscribe) {
cn.ibizlab.businesscentral.util.security.SpringContextHolder.getBean(cn.ibizlab.businesscentral.core.extensions.service.Mail_followersExService.class).add_default_followers(this,et);
}
if (messageinfo && !mail_create_nolog) {
cn.ibizlab.businesscentral.util.security.SpringContextHolder.getBean(cn.ibizlab.businesscentral.core.extensions.service.Mail_messageExService.class).add_default_create_message(this,et);
}
if (messageinfo && !mail_notrack) {
}
return true;
}
@Override
@Transactional
public void createBatch(List<Delivery_carrier> list) {
list.forEach(item->fillParentData(item));
this.saveBatch(list,batchSize);
}
@Override
@Transactional
public boolean update(Delivery_carrier et) {
Delivery_carrier old = new Delivery_carrier() ;
CachedBeanCopier.copy((AopContext.currentProxy() != null ? (IDelivery_carrierService)AopContext.currentProxy() : this).get(et.getId()), old);
boolean mail_notrack = et.get("mail_notrack") != null;
fillParentData(et);
if(!update(et,(Wrapper) et.getUpdateWrapper(true).eq("id",et.getId())))
return false;
CachedBeanCopier.copy((AopContext.currentProxy() != null ? (IDelivery_carrierService)AopContext.currentProxy() : this).get(et.getId()),et);
if (messageinfo && !mail_notrack) {
cn.ibizlab.businesscentral.util.security.SpringContextHolder.getBean(cn.ibizlab.businesscentral.core.extensions.service.Mail_tracking_valueExService.class).message_track(this,old,et);
}
return true;
}
@Override
@Transactional
public void updateBatch(List<Delivery_carrier> list) {
list.forEach(item->fillParentData(item));
updateBatchById(list,batchSize);
}
@Override
@Transactional
public boolean remove(Long key) {
boolean result=removeById(key);
return result ;
}
@Override
@Transactional
public void removeBatch(Collection<Long> idList) {
removeByIds(idList);
}
@Override
@Transactional
public Delivery_carrier get(Long key) {
Delivery_carrier et = getById(key);
if(et==null){
et=new Delivery_carrier();
et.setId(key);
}
else{
}
return et;
}
@Override
public Delivery_carrier getDraft(Delivery_carrier et) {
fillParentData(et);
return et;
}
@Override
public boolean checkKey(Delivery_carrier et) {
return (!ObjectUtils.isEmpty(et.getId()))&&(!Objects.isNull(this.getById(et.getId())));
}
@Override
@Transactional
public boolean save(Delivery_carrier et) {
if(!saveOrUpdate(et))
return false;
return true;
}
@Override
@Transactional
public boolean saveOrUpdate(Delivery_carrier et) {
if (null == et) {
return false;
} else {
return checkKey(et) ? this.update(et) : this.create(et);
}
}
@Override
@Transactional
public boolean saveBatch(Collection<Delivery_carrier> list) {
list.forEach(item->fillParentData(item));
saveOrUpdateBatch(list,batchSize);
return true;
}
@Override
@Transactional
public void saveBatch(List<Delivery_carrier> list) {
list.forEach(item->fillParentData(item));
saveOrUpdateBatch(list,batchSize);
}
@Override
public List<Delivery_carrier> selectByProductId(Long id) {
return baseMapper.selectByProductId(id);
}
@Override
public void removeByProductId(Long id) {
this.remove(new QueryWrapper<Delivery_carrier>().eq("product_id",id));
}
@Override
public List<Delivery_carrier> selectByCompanyId(Long id) {
return baseMapper.selectByCompanyId(id);
}
@Override
public void removeByCompanyId(Long id) {
this.remove(new QueryWrapper<Delivery_carrier>().eq("company_id",id));
}
@Override
public List<Delivery_carrier> selectByCreateUid(Long id) {
return baseMapper.selectByCreateUid(id);
}
@Override
public void removeByCreateUid(Long id) {
this.remove(new QueryWrapper<Delivery_carrier>().eq("create_uid",id));
}
@Override
public List<Delivery_carrier> selectByWriteUid(Long id) {
return baseMapper.selectByWriteUid(id);
}
@Override
public void removeByWriteUid(Long id) {
this.remove(new QueryWrapper<Delivery_carrier>().eq("write_uid",id));
}
/**
* 查询集合 数据集
*/
@Override
public Page<Delivery_carrier> searchDefault(Delivery_carrierSearchContext context) {
com.baomidou.mybatisplus.extension.plugins.pagination.Page<Delivery_carrier> pages=baseMapper.searchDefault(context.getPages(),context,context.getSelectCond());
return new PageImpl<Delivery_carrier>(pages.getRecords(), context.getPageable(), pages.getTotal());
}
/**
* 为当前实体填充父数据(外键值文本、外键值附加数据)
* @param et
*/
private void fillParentData(Delivery_carrier et){
//实体关系[DER1N_DELIVERY_CARRIER_PRODUCT_PRODUCT_PRODUCT_ID]
if(!ObjectUtils.isEmpty(et.getProductId())){
cn.ibizlab.businesscentral.core.odoo_product.domain.Product_product odooProduct=et.getOdooProduct();
if(ObjectUtils.isEmpty(odooProduct)){
cn.ibizlab.businesscentral.core.odoo_product.domain.Product_product majorEntity=productProductService.get(et.getProductId());
et.setOdooProduct(majorEntity);
odooProduct=majorEntity;
}
et.setProductName(odooProduct.getName());
}
//实体关系[DER1N_DELIVERY_CARRIER_RES_COMPANY_COMPANY_ID]
if(!ObjectUtils.isEmpty(et.getCompanyId())){
cn.ibizlab.businesscentral.core.odoo_base.domain.Res_company odooCompany=et.getOdooCompany();
if(ObjectUtils.isEmpty(odooCompany)){
cn.ibizlab.businesscentral.core.odoo_base.domain.Res_company majorEntity=resCompanyService.get(et.getCompanyId());
et.setOdooCompany(majorEntity);
odooCompany=majorEntity;
}
et.setCompanyName(odooCompany.getName());
}
//实体关系[DER1N_DELIVERY_CARRIER_RES_USERS_CREATE_UID]
if(!ObjectUtils.isEmpty(et.getCreateUid())){
cn.ibizlab.businesscentral.core.odoo_base.domain.Res_users odooCreate=et.getOdooCreate();
if(ObjectUtils.isEmpty(odooCreate)){
cn.ibizlab.businesscentral.core.odoo_base.domain.Res_users majorEntity=resUsersService.get(et.getCreateUid());
et.setOdooCreate(majorEntity);
odooCreate=majorEntity;
}
et.setCreateUname(odooCreate.getName());
}
//实体关系[DER1N_DELIVERY_CARRIER_RES_USERS_WRITE_UID]
if(!ObjectUtils.isEmpty(et.getWriteUid())){
cn.ibizlab.businesscentral.core.odoo_base.domain.Res_users odooWrite=et.getOdooWrite();
if(ObjectUtils.isEmpty(odooWrite)){
cn.ibizlab.businesscentral.core.odoo_base.domain.Res_users majorEntity=resUsersService.get(et.getWriteUid());
et.setOdooWrite(majorEntity);
odooWrite=majorEntity;
}
et.setWriteUname(odooWrite.getName());
}
}
@Override
public List<JSONObject> select(String sql, Map param){
return this.baseMapper.selectBySQL(sql,param);
}
@Override
@Transactional
public boolean execute(String sql , Map param){
if (sql == null || sql.isEmpty()) {
return false;
}
if (sql.toLowerCase().trim().startsWith("insert")) {
return this.baseMapper.insertBySQL(sql,param);
}
if (sql.toLowerCase().trim().startsWith("update")) {
return this.baseMapper.updateBySQL(sql,param);
}
if (sql.toLowerCase().trim().startsWith("delete")) {
return this.baseMapper.deleteBySQL(sql,param);
}
log.warn("暂未支持的SQL语法");
return true;
}
}
......@@ -71,6 +71,9 @@ public class Stock_locationServiceImpl extends EBSServiceImpl<Stock_locationMapp
protected cn.ibizlab.businesscentral.core.odoo_base.service.IRes_companyService resCompanyService;
@Autowired
@Lazy
protected cn.ibizlab.businesscentral.core.odoo_base.service.IRes_supplierService resSupplierService;
@Autowired
@Lazy
protected cn.ibizlab.businesscentral.core.odoo_stock.service.IStock_change_product_qtyService stockChangeProductQtyService;
@Autowired
@Lazy
......
......@@ -345,6 +345,9 @@
<!--输出实体[CRM_TEAM]数据结构 -->
<!--输出实体[DELIVERY_CARRIER]数据结构 -->
<!--输出实体[DIGEST_DIGEST]数据结构 -->
......@@ -1382,6 +1385,7 @@
<!--输出实体[CRM_PARTNER_BINDING]外键关系 -->
<!--输出实体[CRM_STAGE]外键关系 -->
<!--输出实体[CRM_TEAM]外键关系 -->
<!--输出实体[DELIVERY_CARRIER]外键关系 -->
<!--输出实体[DIGEST_DIGEST]外键关系 -->
<!--输出实体[DIGEST_TIP]外键关系 -->
<!--输出实体[EVENT_CONFIRM]外键关系 -->
......
......@@ -5,7 +5,7 @@
<!--该方法用于重写mybatis中selectById方法,以实现查询逻辑属性-->
<select id="selectById" resultMap="Res_supplierResultMap" databaseId="postgresql">
<![CDATA[select t1.* from (SELECT (SELECT ARRAY_TO_JSON(ARRAY_AGG(T.*)) FROM (SELECT M2.ID AS SRFKEY, M2.NAME AS SRFMAJORTEXT FROM RES_PARTNER_RES_PARTNER_CATEGORY_REL M1 LEFT JOIN RES_PARTNER_CATEGORY M2 ON M1.CATEGORY_ID = M2.ID WHERE M1.PARTNER_ID =T1.ID ) T) AS CATEGORY_ID, t1.COMPANY_ID, t31.NAME AS COMPANY_ID_TEXT, t1.COUNTRY_ID, t41.NAME AS COUNTRY_ID_TEXT, t1.EMAIL, t1.FUNCTION, t1.ID, t1.MOBILE, t1.NAME, t1.PHONE, t1.STATE_ID, t51.NAME AS STATE_ID_TEXT, t1.TITLE, t11.NAME AS TITLE_TEXT, t1.TYPE, t1.VAT FROM RES_PARTNER t1 LEFT JOIN RES_PARTNER_TITLE t11 ON t1.TITLE = t11.ID LEFT JOIN RES_COMPANY t21 ON t1.COMPANY_ID = t21.ID LEFT JOIN RES_PARTNER t31 ON t21.PARTNER_ID = t31.ID LEFT JOIN RES_COUNTRY t41 ON t1.COUNTRY_ID = t41.ID LEFT JOIN RES_COUNTRY_STATE t51 ON t1.STATE_ID = t51.ID ) t1 where id=#{id}]]>
<![CDATA[select t1.* from (SELECT t1.BARCODE, (SELECT ARRAY_TO_JSON(ARRAY_AGG(T.*)) FROM (SELECT M2.ID AS SRFKEY, M2.NAME AS SRFMAJORTEXT FROM RES_PARTNER_RES_PARTNER_CATEGORY_REL M1 LEFT JOIN RES_PARTNER_CATEGORY M2 ON M1.CATEGORY_ID = M2.ID WHERE M1.PARTNER_ID =T1.ID ) T) AS CATEGORY_ID, t1.COMPANY_ID, t31.NAME AS COMPANY_ID_TEXT, t1.COUNTRY_ID, t41.NAME AS COUNTRY_ID_TEXT, t1.EMAIL, t1.FUNCTION, t1.ID, t1.MOBILE, t1.NAME, t1.PARENT_ID, t81.NAME AS PARENT_NAME, t1.PHONE, t1.REF, t1.STATE_ID, t51.NAME AS STATE_ID_TEXT, t1.TITLE, t11.NAME AS TITLE_TEXT, t1.TYPE, t1.USER_ID, t71.NAME AS USER_NAME, t1.VAT FROM RES_PARTNER t1 LEFT JOIN RES_PARTNER_TITLE t11 ON t1.TITLE = t11.ID LEFT JOIN RES_COMPANY t21 ON t1.COMPANY_ID = t21.ID LEFT JOIN RES_PARTNER t31 ON t21.PARTNER_ID = t31.ID LEFT JOIN RES_COUNTRY t41 ON t1.COUNTRY_ID = t41.ID LEFT JOIN RES_COUNTRY_STATE t51 ON t1.STATE_ID = t51.ID LEFT JOIN RES_USERS t61 ON t1.USER_ID = t61.ID LEFT JOIN RES_PARTNER t71 ON t61.PARTNER_ID = t71.ID LEFT JOIN RES_PARTNER t81 ON t1.PARENT_ID = t81.ID ) t1 where id=#{id}]]>
</select>
<!--通过mybatis将查询结果注入到entity中,通过配置autoMapping="true"由mybatis自动处理映射关系 -->
......@@ -24,26 +24,94 @@
<result property="countryIdText" column="country_id_text" />
<result property="stateIdText" column="state_id_text" />
<result property="stateId" column="state_id" />
<result property="propertyDeliveryCarrierId" column="property_delivery_carrier_id" />
<result property="propertyDeliveryCarrierName" column="property_delivery_carrier_name" />
<result property="propertyPaymentTermId" column="property_payment_term_id" />
<result property="propertyPaymentTermName" column="property_payment_term_name" />
<result property="propertyPurchaseCurrencyId" column="property_purchase_currency_id" />
<result property="propertyPurchaseCurrencyName" column="property_purchase_currency_name" />
<result property="propertyAccountPositionId" column="property_account_position_id" />
<result property="propertyAccountPositionName" column="property_account_position_name" />
<result property="propertyStockCustomer" column="property_stock_customer" />
<result property="propertyStockCustomerName" column="property_stock_customer_name" />
<result property="propertyStockSupplier" column="property_stock_supplier" />
<result property="propertyStockSupplierName" column="property_stock_supplier_name" />
<result property="propertyStockSubcontractor" column="property_stock_subcontractor" />
<result property="propertyStockSubcontractorName" column="property_stock_subcontractor_name" />
<result property="userId" column="user_id" />
<result property="userName" column="user_name" />
<result property="propertyProductPricelist" column="property_product_pricelist" />
<result property="propertyProductPricelistName" column="property_product_pricelist_name" />
<result property="parentId" column="parent_id" />
<result property="parentName" column="parent_name" />
<!--通过mybatis自动注入关系属性[主实体],fetchType="lazy"为懒加载配置 -->
<association property="odooAccountPosition" javaType="cn.ibizlab.businesscentral.core.odoo_account.domain.Account_fiscal_position" column="property_account_position_id" select="cn.ibizlab.businesscentral.core.odoo_account.mapper.Account_fiscal_positionMapper.selectById" fetchType="lazy"></association>
<!--通过mybatis自动注入关系属性[主实体],fetchType="lazy"为懒加载配置 -->
<association property="odooAccountPaymentTerm" javaType="cn.ibizlab.businesscentral.core.odoo_account.domain.Account_payment_term" column="property_payment_term_id" select="cn.ibizlab.businesscentral.core.odoo_account.mapper.Account_payment_termMapper.selectById" fetchType="lazy"></association>
<!--通过mybatis自动注入关系属性[主实体],fetchType="lazy"为懒加载配置 -->
<association property="odooPurchasePaymentTerm" javaType="cn.ibizlab.businesscentral.core.odoo_account.domain.Account_payment_term" column="property_supplier_payment_term_id" select="cn.ibizlab.businesscentral.core.odoo_account.mapper.Account_payment_termMapper.selectById" fetchType="lazy"></association>
<!--通过mybatis自动注入关系属性[主实体],fetchType="lazy"为懒加载配置 -->
<association property="odooDeliveryCarrier" javaType="cn.ibizlab.businesscentral.core.odoo_stock.domain.Delivery_carrier" column="property_delivery_carrier_id" select="cn.ibizlab.businesscentral.core.odoo_stock.mapper.Delivery_carrierMapper.selectById" fetchType="lazy"></association>
<!--通过mybatis自动注入关系属性[主实体],fetchType="lazy"为懒加载配置 -->
<association property="odooPricelist" javaType="cn.ibizlab.businesscentral.core.odoo_product.domain.Product_pricelist" column="property_product_pricelist" select="cn.ibizlab.businesscentral.core.odoo_product.mapper.Product_pricelistMapper.selectById" fetchType="lazy"></association>
<!--通过mybatis自动注入关系属性[主实体],fetchType="lazy"为懒加载配置 -->
<association property="odooCompany" javaType="cn.ibizlab.businesscentral.core.odoo_base.domain.Res_company" column="company_id" select="cn.ibizlab.businesscentral.core.odoo_base.mapper.Res_companyMapper.selectById" fetchType="lazy"></association>
<!--通过mybatis自动注入关系属性[主实体],fetchType="lazy"为懒加载配置 -->
<association property="odooCountry" javaType="cn.ibizlab.businesscentral.core.odoo_base.domain.Res_country" column="country_id" select="cn.ibizlab.businesscentral.core.odoo_base.mapper.Res_countryMapper.selectById" fetchType="lazy"></association>
<!--通过mybatis自动注入关系属性[主实体],fetchType="lazy"为懒加载配置 -->
<association property="odooState" javaType="cn.ibizlab.businesscentral.core.odoo_base.domain.Res_country_state" column="state_id" select="cn.ibizlab.businesscentral.core.odoo_base.mapper.Res_country_stateMapper.selectById" fetchType="lazy"></association>
<!--通过mybatis自动注入关系属性[主实体],fetchType="lazy"为懒加载配置 -->
<association property="odooCurrency" javaType="cn.ibizlab.businesscentral.core.odoo_base.domain.Res_currency" column="property_purchase_currency_id" select="cn.ibizlab.businesscentral.core.odoo_base.mapper.Res_currencyMapper.selectById" fetchType="lazy"></association>
<!--通过mybatis自动注入关系属性[主实体],fetchType="lazy"为懒加载配置 -->
<association property="odooParent" javaType="cn.ibizlab.businesscentral.core.odoo_base.domain.Res_partner" column="parent_id" select="cn.ibizlab.businesscentral.core.odoo_base.mapper.Res_partnerMapper.selectById" fetchType="lazy"></association>
<!--通过mybatis自动注入关系属性[主实体],fetchType="lazy"为懒加载配置 -->
<association property="odooTitle" javaType="cn.ibizlab.businesscentral.core.odoo_base.domain.Res_partner_title" column="title" select="cn.ibizlab.businesscentral.core.odoo_base.mapper.Res_partner_titleMapper.selectById" fetchType="lazy"></association>
<!--通过mybatis自动注入关系属性[主实体],fetchType="lazy"为懒加载配置 -->
<association property="odooUser" javaType="cn.ibizlab.businesscentral.core.odoo_base.domain.Res_users" column="user_id" select="cn.ibizlab.businesscentral.core.odoo_base.mapper.Res_usersMapper.selectById" fetchType="lazy"></association>
<!--通过mybatis自动注入关系属性[主实体],fetchType="lazy"为懒加载配置 -->
<association property="odooCustomerLocation" javaType="cn.ibizlab.businesscentral.core.odoo_stock.domain.Stock_location" column="property_stock_customer" select="cn.ibizlab.businesscentral.core.odoo_stock.mapper.Stock_locationMapper.selectById" fetchType="lazy"></association>
<!--通过mybatis自动注入关系属性[主实体],fetchType="lazy"为懒加载配置 -->
<association property="odooSubcontractorLocation" javaType="cn.ibizlab.businesscentral.core.odoo_stock.domain.Stock_location" column="property_stock_subcontractor" select="cn.ibizlab.businesscentral.core.odoo_stock.mapper.Stock_locationMapper.selectById" fetchType="lazy"></association>
<!--通过mybatis自动注入关系属性[主实体],fetchType="lazy"为懒加载配置 -->
<association property="odooVendorLocation" javaType="cn.ibizlab.businesscentral.core.odoo_stock.domain.Stock_location" column="property_stock_supplier" select="cn.ibizlab.businesscentral.core.odoo_stock.mapper.Stock_locationMapper.selectById" fetchType="lazy"></association>
</resultMap>
<!--关系实体暴露select方法供主实体通过外键查询关系实体数据[实体关系名称:DER1N_RES_SUPPLIER_ACCOUNT_FISCAL_POSITION_PROPERTY_ACCOUNT_POSITION_ID] -->
<select id="selectByPropertyAccountPositionId" resultMap="Res_supplierResultMap">
select t1.* from (
<include refid="Default" />
) t1
where property_account_position_id=#{id}
</select>
<!--关系实体暴露select方法供主实体通过外键查询关系实体数据[实体关系名称:DER1N_RES_SUPPLIER_ACCOUNT_PAYMENT_TERM_PROPERTY_PAYMENT_TERM_ID] -->
<select id="selectByPropertyPaymentTermId" resultMap="Res_supplierResultMap">
select t1.* from (
<include refid="Default" />
) t1
where property_payment_term_id=#{id}
</select>
<!--关系实体暴露select方法供主实体通过外键查询关系实体数据[实体关系名称:DER1N_RES_SUPPLIER_ACCOUNT_PAYMENT_TERM_PROPERTY_SUPPLIER_PAYMENT_TERM_ID] -->
<select id="selectByPropertySupplierPaymentTermId" resultMap="Res_supplierResultMap">
select t1.* from (
<include refid="Default" />
) t1
where property_supplier_payment_term_id=#{id}
</select>
<!--关系实体暴露select方法供主实体通过外键查询关系实体数据[实体关系名称:DER1N_RES_SUPPLIER_DELIVERY_CARRIER_PROPERTY_DELIVERY_CARRIER_ID] -->
<select id="selectByPropertyDeliveryCarrierId" resultMap="Res_supplierResultMap">
select t1.* from (
<include refid="Default" />
) t1
where property_delivery_carrier_id=#{id}
</select>
<!--关系实体暴露select方法供主实体通过外键查询关系实体数据[实体关系名称:DER1N_RES_SUPPLIER_PRODUCT_PRICELIST_PROPERTY_PRODUCT_PRICELIST] -->
<select id="selectByPropertyProductPricelist" resultMap="Res_supplierResultMap">
select t1.* from (
<include refid="Default" />
) t1
where property_product_pricelist=#{id}
</select>
<!--关系实体暴露select方法供主实体通过外键查询关系实体数据[实体关系名称:DER1N_RES_SUPPLIER_RES_COMPANY_COMPANY_ID] -->
<select id="selectByCompanyId" resultMap="Res_supplierResultMap">
......@@ -65,6 +133,20 @@
<include refid="Default" />
) t1
where state_id=#{id}
</select>
<!--关系实体暴露select方法供主实体通过外键查询关系实体数据[实体关系名称:DER1N_RES_SUPPLIER_RES_CURRENCY_PROPERTY_PURCHASE_CURRENCY_ID] -->
<select id="selectByPropertyPurchaseCurrencyId" resultMap="Res_supplierResultMap">
select t1.* from (
<include refid="Default" />
) t1
where property_purchase_currency_id=#{id}
</select>
<!--关系实体暴露select方法供主实体通过外键查询关系实体数据[实体关系名称:DER1N_RES_SUPPLIER_RES_PARTNER_PARENT_ID] -->
<select id="selectByParentId" resultMap="Res_supplierResultMap">
select t1.* from (
<include refid="Default" />
) t1
where parent_id=#{id}
</select>
<!--关系实体暴露select方法供主实体通过外键查询关系实体数据[实体关系名称:DER1N_RES_SUPPLIER_RES_PARTNER_TITLE_TITLE] -->
<select id="selectByTitle" resultMap="Res_supplierResultMap">
......@@ -72,6 +154,34 @@
<include refid="Default" />
) t1
where title=#{id}
</select>
<!--关系实体暴露select方法供主实体通过外键查询关系实体数据[实体关系名称:DER1N_RES_SUPPLIER_RES_USERS_USER_ID] -->
<select id="selectByUserId" resultMap="Res_supplierResultMap">
select t1.* from (
<include refid="Default" />
) t1
where user_id=#{id}
</select>
<!--关系实体暴露select方法供主实体通过外键查询关系实体数据[实体关系名称:DER1N_RES_SUPPLIER_STOCK_LOCATION_PROPERTY_STOCK_CUSTOMER] -->
<select id="selectByPropertyStockCustomer" resultMap="Res_supplierResultMap">
select t1.* from (
<include refid="Default" />
) t1
where property_stock_customer=#{id}
</select>
<!--关系实体暴露select方法供主实体通过外键查询关系实体数据[实体关系名称:DER1N_RES_SUPPLIER_STOCK_LOCATION_PROPERTY_STOCK_SUBCONTRACTOR] -->
<select id="selectByPropertyStockSubcontractor" resultMap="Res_supplierResultMap">
select t1.* from (
<include refid="Default" />
) t1
where property_stock_subcontractor=#{id}
</select>
<!--关系实体暴露select方法供主实体通过外键查询关系实体数据[实体关系名称:DER1N_RES_SUPPLIER_STOCK_LOCATION_PROPERTY_STOCK_SUPPLIER] -->
<select id="selectByPropertyStockSupplier" resultMap="Res_supplierResultMap">
select t1.* from (
<include refid="Default" />
) t1
where property_stock_supplier=#{id}
</select>
<!--数据集合[Default]-->
......@@ -85,12 +195,12 @@
<!--数据查询[Default]-->
<sql id="Default" databaseId="postgresql">
<![CDATA[ SELECT t1.COMPANY_ID, t31.NAME AS COMPANY_ID_TEXT, t1.COUNTRY_ID, t41.NAME AS COUNTRY_ID_TEXT, t1.EMAIL, t1.FUNCTION, t1.ID, t1.MOBILE, t1.NAME, t1.PHONE, t1.STATE_ID, t51.NAME AS STATE_ID_TEXT, t1.TITLE, t11.NAME AS TITLE_TEXT, t1.TYPE, t1.VAT FROM RES_PARTNER t1 LEFT JOIN RES_PARTNER_TITLE t11 ON t1.TITLE = t11.ID LEFT JOIN RES_COMPANY t21 ON t1.COMPANY_ID = t21.ID LEFT JOIN RES_PARTNER t31 ON t21.PARTNER_ID = t31.ID LEFT JOIN RES_COUNTRY t41 ON t1.COUNTRY_ID = t41.ID LEFT JOIN RES_COUNTRY_STATE t51 ON t1.STATE_ID = t51.ID
<![CDATA[ SELECT t1.BARCODE, t1.COMPANY_ID, t31.NAME AS COMPANY_ID_TEXT, t1.COUNTRY_ID, t41.NAME AS COUNTRY_ID_TEXT, t1.EMAIL, t1.FUNCTION, t1.ID, t1.MOBILE, t1.NAME, t1.PARENT_ID, t81.NAME AS PARENT_NAME, t1.PHONE, t1.REF, t1.STATE_ID, t51.NAME AS STATE_ID_TEXT, t1.TITLE, t11.NAME AS TITLE_TEXT, t1.TYPE, t1.USER_ID, t71.NAME AS USER_NAME, t1.VAT FROM RES_PARTNER t1 LEFT JOIN RES_PARTNER_TITLE t11 ON t1.TITLE = t11.ID LEFT JOIN RES_COMPANY t21 ON t1.COMPANY_ID = t21.ID LEFT JOIN RES_PARTNER t31 ON t21.PARTNER_ID = t31.ID LEFT JOIN RES_COUNTRY t41 ON t1.COUNTRY_ID = t41.ID LEFT JOIN RES_COUNTRY_STATE t51 ON t1.STATE_ID = t51.ID LEFT JOIN RES_USERS t61 ON t1.USER_ID = t61.ID LEFT JOIN RES_PARTNER t71 ON t61.PARTNER_ID = t71.ID LEFT JOIN RES_PARTNER t81 ON t1.PARENT_ID = t81.ID
]]>
</sql>
<!--数据查询[View]-->
<sql id="View" databaseId="postgresql">
<![CDATA[ SELECT (SELECT ARRAY_TO_JSON(ARRAY_AGG(T.*)) FROM (SELECT M2.ID AS SRFKEY, M2.NAME AS SRFMAJORTEXT FROM RES_PARTNER_RES_PARTNER_CATEGORY_REL M1 LEFT JOIN RES_PARTNER_CATEGORY M2 ON M1.CATEGORY_ID = M2.ID WHERE M1.PARTNER_ID =T1.ID ) T) AS CATEGORY_ID, t1.COMPANY_ID, t31.NAME AS COMPANY_ID_TEXT, t1.COUNTRY_ID, t41.NAME AS COUNTRY_ID_TEXT, t1.EMAIL, t1.FUNCTION, t1.ID, t1.MOBILE, t1.NAME, t1.PHONE, t1.STATE_ID, t51.NAME AS STATE_ID_TEXT, t1.TITLE, t11.NAME AS TITLE_TEXT, t1.TYPE, t1.VAT FROM RES_PARTNER t1 LEFT JOIN RES_PARTNER_TITLE t11 ON t1.TITLE = t11.ID LEFT JOIN RES_COMPANY t21 ON t1.COMPANY_ID = t21.ID LEFT JOIN RES_PARTNER t31 ON t21.PARTNER_ID = t31.ID LEFT JOIN RES_COUNTRY t41 ON t1.COUNTRY_ID = t41.ID LEFT JOIN RES_COUNTRY_STATE t51 ON t1.STATE_ID = t51.ID
<![CDATA[ SELECT t1.BARCODE, (SELECT ARRAY_TO_JSON(ARRAY_AGG(T.*)) FROM (SELECT M2.ID AS SRFKEY, M2.NAME AS SRFMAJORTEXT FROM RES_PARTNER_RES_PARTNER_CATEGORY_REL M1 LEFT JOIN RES_PARTNER_CATEGORY M2 ON M1.CATEGORY_ID = M2.ID WHERE M1.PARTNER_ID =T1.ID ) T) AS CATEGORY_ID, t1.COMPANY_ID, t31.NAME AS COMPANY_ID_TEXT, t1.COUNTRY_ID, t41.NAME AS COUNTRY_ID_TEXT, t1.EMAIL, t1.FUNCTION, t1.ID, t1.MOBILE, t1.NAME, t1.PARENT_ID, t81.NAME AS PARENT_NAME, t1.PHONE, t1.REF, t1.STATE_ID, t51.NAME AS STATE_ID_TEXT, t1.TITLE, t11.NAME AS TITLE_TEXT, t1.TYPE, t1.USER_ID, t71.NAME AS USER_NAME, t1.VAT FROM RES_PARTNER t1 LEFT JOIN RES_PARTNER_TITLE t11 ON t1.TITLE = t11.ID LEFT JOIN RES_COMPANY t21 ON t1.COMPANY_ID = t21.ID LEFT JOIN RES_PARTNER t31 ON t21.PARTNER_ID = t31.ID LEFT JOIN RES_COUNTRY t41 ON t1.COUNTRY_ID = t41.ID LEFT JOIN RES_COUNTRY_STATE t51 ON t1.STATE_ID = t51.ID LEFT JOIN RES_USERS t61 ON t1.USER_ID = t61.ID LEFT JOIN RES_PARTNER t71 ON t61.PARTNER_ID = t71.ID LEFT JOIN RES_PARTNER t81 ON t1.PARENT_ID = t81.ID
]]>
</sql>
......
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="cn.ibizlab.businesscentral.core.odoo_stock.mapper.Delivery_carrierMapper">
<!--该方法用于重写mybatis中selectById方法,以实现查询逻辑属性-->
<select id="selectById" resultMap="Delivery_carrierResultMap" databaseId="postgresql">
<![CDATA[select t1.* from (SELECT t1.ACTIVE, t1.AMOUNT, t1.COMPANY_ID, t21.NAME AS COMPANY_NAME, t1.CREATE_DATE, t1.CREATE_UID, t81.NAME AS CREATE_UNAME, t1.DEBUG_LOGGING, t1.DELIVERY_TYPE, t1.FIXED_PRICE, t1.FREE_OVER, t1.GET_RETURN_LABEL_FROM_PORTAL, t1.ID, t1.INTEGRATION_LEVEL, t1.INVOICE_POLICY, t1.IS_PUBLISHED, t1.MARGIN, t1.NAME, t1.PRODUCT_ID, t41.NAME AS PRODUCT_NAME, t1.PROD_ENVIRONMENT, t1.RETURN_LABEL_ON_DELIVERY, t1.SEQUENCE, t1.WRITE_DATE, t1.WRITE_UID, t61.NAME AS WRITE_UNAME, t1.ZIP_FROM, t1.ZIP_TO FROM DELIVERY_CARRIER t1 LEFT JOIN RES_COMPANY t11 ON t1.COMPANY_ID = t11.ID LEFT JOIN RES_PARTNER t21 ON t11.PARTNER_ID = t21.ID LEFT JOIN PRODUCT_PRODUCT t31 ON t1.PRODUCT_ID = t31.ID LEFT JOIN PRODUCT_TEMPLATE t41 ON t31.PRODUCT_TMPL_ID = t41.ID LEFT JOIN RES_USERS t51 ON t1.WRITE_UID = t51.ID LEFT JOIN RES_PARTNER t61 ON t51.PARTNER_ID = t61.ID LEFT JOIN RES_USERS t71 ON t1.CREATE_UID = t71.ID LEFT JOIN RES_PARTNER t81 ON t71.PARTNER_ID = t81.ID ) t1 where id=#{id}]]>
</select>
<!--通过mybatis将查询结果注入到entity中,通过配置autoMapping="true"由mybatis自动处理映射关系 -->
<resultMap id="Delivery_carrierResultMap" type="cn.ibizlab.businesscentral.core.odoo_stock.domain.Delivery_carrier" autoMapping="true">
<id property="id" column="id" /><!--主键字段映射-->
<result property="integrationLevel" column="integration_level" />
<result property="prodEnvironment" column="prod_environment" />
<result property="debugLogging" column="debug_logging" />
<result property="companyId" column="company_id" />
<result property="productId" column="product_id" />
<result property="companyName" column="company_name" />
<result property="productName" column="product_name" />
<result property="invoicePolicy" column="invoice_policy" />
<result property="zipFrom" column="zip_from" />
<result property="zipTo" column="zip_to" />
<result property="freeOver" column="free_over" />
<result property="returnLabelOnDelivery" column="return_label_on_delivery" />
<result property="getReturnLabelFromPortal" column="get_return_label_from_portal" />
<result property="fixedPrice" column="fixed_price" />
<result property="deliveryType" column="delivery_type" />
<result property="createDate" column="create_date" />
<result property="writeDate" column="write_date" />
<result property="isPublished" column="is_published" />
<result property="writeUid" column="write_uid" />
<result property="createUid" column="create_uid" />
<result property="writeUname" column="write_uname" />
<result property="createUname" column="create_uname" />
<!--通过mybatis自动注入关系属性[主实体],fetchType="lazy"为懒加载配置 -->
<association property="odooProduct" javaType="cn.ibizlab.businesscentral.core.odoo_product.domain.Product_product" column="product_id" select="cn.ibizlab.businesscentral.core.odoo_product.mapper.Product_productMapper.selectById" fetchType="lazy"></association>
<!--通过mybatis自动注入关系属性[主实体],fetchType="lazy"为懒加载配置 -->
<association property="odooCompany" javaType="cn.ibizlab.businesscentral.core.odoo_base.domain.Res_company" column="company_id" select="cn.ibizlab.businesscentral.core.odoo_base.mapper.Res_companyMapper.selectById" fetchType="lazy"></association>
<!--通过mybatis自动注入关系属性[主实体],fetchType="lazy"为懒加载配置 -->
<association property="odooCreate" javaType="cn.ibizlab.businesscentral.core.odoo_base.domain.Res_users" column="create_uid" select="cn.ibizlab.businesscentral.core.odoo_base.mapper.Res_usersMapper.selectById" fetchType="lazy"></association>
<!--通过mybatis自动注入关系属性[主实体],fetchType="lazy"为懒加载配置 -->
<association property="odooWrite" javaType="cn.ibizlab.businesscentral.core.odoo_base.domain.Res_users" column="write_uid" select="cn.ibizlab.businesscentral.core.odoo_base.mapper.Res_usersMapper.selectById" fetchType="lazy"></association>
</resultMap>
<!--关系实体暴露select方法供主实体通过外键查询关系实体数据[实体关系名称:DER1N_DELIVERY_CARRIER_PRODUCT_PRODUCT_PRODUCT_ID] -->
<select id="selectByProductId" resultMap="Delivery_carrierResultMap">
select t1.* from (
<include refid="Default" />
) t1
where product_id=#{id}
</select>
<!--关系实体暴露select方法供主实体通过外键查询关系实体数据[实体关系名称:DER1N_DELIVERY_CARRIER_RES_COMPANY_COMPANY_ID] -->
<select id="selectByCompanyId" resultMap="Delivery_carrierResultMap">
select t1.* from (
<include refid="Default" />
) t1
where company_id=#{id}
</select>
<!--关系实体暴露select方法供主实体通过外键查询关系实体数据[实体关系名称:DER1N_DELIVERY_CARRIER_RES_USERS_CREATE_UID] -->
<select id="selectByCreateUid" resultMap="Delivery_carrierResultMap">
select t1.* from (
<include refid="Default" />
) t1
where create_uid=#{id}
</select>
<!--关系实体暴露select方法供主实体通过外键查询关系实体数据[实体关系名称:DER1N_DELIVERY_CARRIER_RES_USERS_WRITE_UID] -->
<select id="selectByWriteUid" resultMap="Delivery_carrierResultMap">
select t1.* from (
<include refid="Default" />
) t1
where write_uid=#{id}
</select>
<!--数据集合[Default]-->
<select id="searchDefault" parameterType="cn.ibizlab.businesscentral.core.odoo_stock.filter.Delivery_carrierSearchContext" resultMap="Delivery_carrierResultMap">
select t1.* from (
<include refid="Default" />
)t1
<where><if test="ew!=null and ew.sqlSegment!=null and !ew.emptyOfWhere">${ew.sqlSegment}</if></where>
<if test="ew!=null and ew.sqlSegment!=null and ew.emptyOfWhere">${ew.sqlSegment}</if>
</select>
<!--数据查询[Default]-->
<sql id="Default" databaseId="postgresql">
<![CDATA[ SELECT t1.ACTIVE, t1.AMOUNT, t1.COMPANY_ID, t21.NAME AS COMPANY_NAME, t1.CREATE_DATE, t1.CREATE_UID, t81.NAME AS CREATE_UNAME, t1.DEBUG_LOGGING, t1.DELIVERY_TYPE, t1.FIXED_PRICE, t1.FREE_OVER, t1.GET_RETURN_LABEL_FROM_PORTAL, t1.ID, t1.INTEGRATION_LEVEL, t1.INVOICE_POLICY, t1.IS_PUBLISHED, t1.MARGIN, t1.NAME, t1.PRODUCT_ID, t41.NAME AS PRODUCT_NAME, t1.PROD_ENVIRONMENT, t1.RETURN_LABEL_ON_DELIVERY, t1.SEQUENCE, t1.WRITE_DATE, t1.WRITE_UID, t61.NAME AS WRITE_UNAME, t1.ZIP_FROM, t1.ZIP_TO FROM DELIVERY_CARRIER t1 LEFT JOIN RES_COMPANY t11 ON t1.COMPANY_ID = t11.ID LEFT JOIN RES_PARTNER t21 ON t11.PARTNER_ID = t21.ID LEFT JOIN PRODUCT_PRODUCT t31 ON t1.PRODUCT_ID = t31.ID LEFT JOIN PRODUCT_TEMPLATE t41 ON t31.PRODUCT_TMPL_ID = t41.ID LEFT JOIN RES_USERS t51 ON t1.WRITE_UID = t51.ID LEFT JOIN RES_PARTNER t61 ON t51.PARTNER_ID = t61.ID LEFT JOIN RES_USERS t71 ON t1.CREATE_UID = t71.ID LEFT JOIN RES_PARTNER t81 ON t71.PARTNER_ID = t81.ID
]]>
</sql>
<!--数据查询[View]-->
<sql id="View" databaseId="postgresql">
<![CDATA[ SELECT t1.ACTIVE, t1.AMOUNT, t1.COMPANY_ID, t21.NAME AS COMPANY_NAME, t1.CREATE_DATE, t1.CREATE_UID, t81.NAME AS CREATE_UNAME, t1.DEBUG_LOGGING, t1.DELIVERY_TYPE, t1.FIXED_PRICE, t1.FREE_OVER, t1.GET_RETURN_LABEL_FROM_PORTAL, t1.ID, t1.INTEGRATION_LEVEL, t1.INVOICE_POLICY, t1.IS_PUBLISHED, t1.MARGIN, t1.NAME, t1.PRODUCT_ID, t41.NAME AS PRODUCT_NAME, t1.PROD_ENVIRONMENT, t1.RETURN_LABEL_ON_DELIVERY, t1.SEQUENCE, t1.WRITE_DATE, t1.WRITE_UID, t61.NAME AS WRITE_UNAME, t1.ZIP_FROM, t1.ZIP_TO FROM DELIVERY_CARRIER t1 LEFT JOIN RES_COMPANY t11 ON t1.COMPANY_ID = t11.ID LEFT JOIN RES_PARTNER t21 ON t11.PARTNER_ID = t21.ID LEFT JOIN PRODUCT_PRODUCT t31 ON t1.PRODUCT_ID = t31.ID LEFT JOIN PRODUCT_TEMPLATE t41 ON t31.PRODUCT_TMPL_ID = t41.ID LEFT JOIN RES_USERS t51 ON t1.WRITE_UID = t51.ID LEFT JOIN RES_PARTNER t61 ON t51.PARTNER_ID = t61.ID LEFT JOIN RES_USERS t71 ON t1.CREATE_UID = t71.ID LEFT JOIN RES_PARTNER t81 ON t71.PARTNER_ID = t81.ID
]]>
</sql>
</mapper>
......@@ -9967,6 +9967,12 @@
"entity_name":"PURCHASE_REPORT",
"ref_entity_name":"ACCOUNT_FISCAL_POSITION"
},
{"name":"DER1N_RES_SUPPLIER_ACCOUNT_FISCAL_POSITION_PROPERTY_ACCOUNT_POSITION_ID",
"relation_type":"DER1N",
"code_name":"Odoo_account_position",
"entity_name":"RES_SUPPLIER",
"ref_entity_name":"ACCOUNT_FISCAL_POSITION"
},
{"name":"DER1N_SALE_ORDER__ACCOUNT_FISCAL_POSITION__FISCAL_POSITION_ID",
"relation_type":"DER1N",
"code_name":"Odoo_fiscal_position",
......@@ -23957,6 +23963,12 @@
"entity_name":"PURCHASE_ORDER",
"ref_entity_name":"ACCOUNT_PAYMENT_TERM"
},
{"name":"DER1N_RES_SUPPLIER_ACCOUNT_PAYMENT_TERM_PROPERTY_PAYMENT_TERM_ID",
"relation_type":"DER1N",
"code_name":"Odoo_account_payment_term",
"entity_name":"RES_SUPPLIER",
"ref_entity_name":"ACCOUNT_PAYMENT_TERM"
},
{"name":"DER1N_RES_SUPPLIER_ACCOUNT_PAYMENT_TERM_PROPERTY_SUPPLIER_PAYMENT_TERM_ID",
"relation_type":"DER1N",
"code_name":"Odoo_purchase_payment_term",
......@@ -45504,6 +45516,458 @@
"ref_entity_name":"RES_USERS"
}
]
}
,
{
"entity_name":"DELIVERY_CARRIER",
"logic_name":"送货方式",
"code_name":"Delivery_carrier",
"table_name":"DELIVERY_CARRIER",
"system_id":"iBizBusinessCentral",
"system_name":"iBiz商业中心",
"fields":[
{
"fieldname":"ID" ,
"codename":"Id",
"field_logic_name":"ID",
"entity_name":"Delivery_carrier",
"field_type":"ACID",
"nullable":1,
"physical_field":1,
"data_type":"BIGINT",
"data_length":20,
"key_field":1,
"show_order":1000,
"major_field":0
},
{
"fieldname":"NAME" ,
"codename":"Name",
"field_logic_name":"名称",
"entity_name":"Delivery_carrier",
"field_type":"TEXT",
"nullable":1,
"physical_field":1,
"data_type":"VARCHAR",
"data_length":100,
"key_field":0,
"show_order":1000,
"major_field":1
},
{
"fieldname":"ACTIVE" ,
"codename":"Active",
"field_logic_name":"有效",
"entity_name":"Delivery_carrier",
"field_type":"TRUEFALSE",
"nullable":1,
"physical_field":1,
"data_type":"BIT",
"key_field":0,
"show_order":1000,
"major_field":0
},
{
"fieldname":"SEQUENCE" ,
"codename":"Sequence",
"field_logic_name":"序号",
"entity_name":"Delivery_carrier",
"field_type":"INT",
"nullable":1,
"physical_field":1,
"data_type":"INT",
"key_field":0,
"show_order":1000,
"major_field":0
},
{
"fieldname":"INTEGRATION_LEVEL" ,
"codename":"Integration_level",
"field_logic_name":"集成级别",
"entity_name":"Delivery_carrier",
"field_type":"SSCODELIST",
"nullable":1,
"physical_field":1,
"data_type":"VARCHAR",
"data_length":60,
"key_field":0,
"show_order":1000,
"major_field":0
},
{
"fieldname":"PROD_ENVIRONMENT" ,
"codename":"Prod_environment",
"field_logic_name":"生产环境",
"entity_name":"Delivery_carrier",
"field_type":"TRUEFALSE",
"nullable":1,
"physical_field":1,
"data_type":"BIT",
"key_field":0,
"show_order":1000,
"major_field":0
},
{
"fieldname":"DEBUG_LOGGING" ,
"codename":"Debug_logging",
"field_logic_name":"调试记录",
"entity_name":"Delivery_carrier",
"field_type":"TRUEFALSE",
"nullable":1,
"physical_field":1,
"data_type":"BIT",
"key_field":0,
"show_order":1000,
"major_field":0
},
{
"fieldname":"COMPANY_ID" ,
"codename":"Company_id",
"field_logic_name":"ID",
"entity_name":"Delivery_carrier",
"ref_de":"RES_COMPANY",
"ref_field_name":"ID",
"relation_name":"DER1N_DELIVERY_CARRIER_RES_COMPANY_COMPANY_ID",
"relation_codename":"Odoo_company",
"field_type":"PICKUP",
"nullable":1,
"physical_field":1,
"data_type":"BIGINT",
"key_field":0,
"show_order":1000,
"major_field":0
},
{
"fieldname":"PRODUCT_ID" ,
"codename":"Product_id",
"field_logic_name":"ID",
"entity_name":"Delivery_carrier",
"ref_de":"PRODUCT_PRODUCT",
"ref_field_name":"ID",
"relation_name":"DER1N_DELIVERY_CARRIER_PRODUCT_PRODUCT_PRODUCT_ID",
"relation_codename":"Odoo_product",
"field_type":"PICKUP",
"nullable":1,
"physical_field":1,
"data_type":"BIGINT",
"key_field":0,
"show_order":1000,
"major_field":0
},
{
"fieldname":"COMPANY_NAME" ,
"codename":"Company_name",
"field_logic_name":"公司名称",
"entity_name":"Delivery_carrier",
"ref_de":"RES_COMPANY",
"ref_field_name":"NAME",
"relation_name":"DER1N_DELIVERY_CARRIER_RES_COMPANY_COMPANY_ID",
"relation_codename":"Odoo_company",
"field_type":"PICKUPTEXT",
"nullable":1,
"physical_field":0,
"data_type":"VARCHAR",
"data_length":100,
"key_field":0,
"show_order":1000,
"major_field":0
},
{
"fieldname":"PRODUCT_NAME" ,
"codename":"Product_name",
"field_logic_name":"名称",
"entity_name":"Delivery_carrier",
"ref_de":"PRODUCT_PRODUCT",
"ref_field_name":"NAME",
"relation_name":"DER1N_DELIVERY_CARRIER_PRODUCT_PRODUCT_PRODUCT_ID",
"relation_codename":"Odoo_product",
"field_type":"PICKUPTEXT",
"nullable":1,
"physical_field":0,
"data_type":"VARCHAR",
"data_length":100,
"key_field":0,
"show_order":1000,
"major_field":0
},
{
"fieldname":"INVOICE_POLICY" ,
"codename":"Invoice_policy",
"field_logic_name":"发票原则",
"entity_name":"Delivery_carrier",
"field_type":"SSCODELIST",
"nullable":1,
"physical_field":1,
"data_type":"VARCHAR",
"data_length":60,
"key_field":0,
"show_order":1000,
"major_field":0
},
{
"fieldname":"ZIP_FROM" ,
"codename":"Zip_from",
"field_logic_name":"邮编从",
"entity_name":"Delivery_carrier",
"field_type":"TEXT",
"nullable":1,
"physical_field":1,
"data_type":"VARCHAR",
"data_length":100,
"key_field":0,
"show_order":1000,
"major_field":0
},
{
"fieldname":"ZIP_TO" ,
"codename":"Zip_to",
"field_logic_name":"邮编到",
"entity_name":"Delivery_carrier",
"field_type":"TEXT",
"nullable":1,
"physical_field":1,
"data_type":"VARCHAR",
"data_length":100,
"key_field":0,
"show_order":1000,
"major_field":0
},
{
"fieldname":"MARGIN" ,
"codename":"Margin",
"field_logic_name":"利润率",
"entity_name":"Delivery_carrier",
"field_type":"FLOAT",
"nullable":1,
"physical_field":1,
"data_type":"FLOAT",
"key_field":0,
"show_order":1000,
"major_field":0
},
{
"fieldname":"FREE_OVER" ,
"codename":"Free_over",
"field_logic_name":"如果订货量大则免费",
"entity_name":"Delivery_carrier",
"field_type":"TRUEFALSE",
"nullable":1,
"physical_field":1,
"data_type":"BIT",
"key_field":0,
"show_order":1000,
"major_field":0
},
{
"fieldname":"AMOUNT" ,
"codename":"Amount",
"field_logic_name":"金额",
"entity_name":"Delivery_carrier",
"field_type":"FLOAT",
"nullable":1,
"physical_field":1,
"data_type":"FLOAT",
"key_field":0,
"show_order":1000,
"major_field":0
},
{
"fieldname":"RETURN_LABEL_ON_DELIVERY" ,
"codename":"Return_label_on_delivery",
"field_logic_name":"交易退货标签",
"entity_name":"Delivery_carrier",
"field_type":"TRUEFALSE",
"nullable":1,
"physical_field":1,
"data_type":"BIT",
"key_field":0,
"show_order":1000,
"major_field":0
},
{
"fieldname":"GET_RETURN_LABEL_FROM_PORTAL" ,
"codename":"Get_return_label_from_portal",
"field_logic_name":"从门户获取返回标签",
"entity_name":"Delivery_carrier",
"field_type":"TRUEFALSE",
"nullable":1,
"physical_field":1,
"data_type":"BIT",
"key_field":0,
"show_order":1000,
"major_field":0
},
{
"fieldname":"FIXED_PRICE" ,
"codename":"Fixed_price",
"field_logic_name":"固定价格",
"entity_name":"Delivery_carrier",
"field_type":"FLOAT",
"nullable":1,
"physical_field":1,
"data_type":"FLOAT",
"key_field":0,
"show_order":1000,
"major_field":0
},
{
"fieldname":"DELIVERY_TYPE" ,
"codename":"Delivery_type",
"field_logic_name":"供应商",
"entity_name":"Delivery_carrier",
"field_type":"SSCODELIST",
"nullable":1,
"physical_field":1,
"data_type":"VARCHAR",
"data_length":60,
"key_field":0,
"show_order":1000,
"major_field":0
},
{
"fieldname":"CREATE_DATE" ,
"codename":"Create_date",
"field_logic_name":"创建时间",
"entity_name":"Delivery_carrier",
"field_type":"DATETIME",
"nullable":1,
"physical_field":1,
"data_type":"DATETIME",
"key_field":0,
"show_order":1000,
"major_field":0
},
{
"fieldname":"WRITE_DATE" ,
"codename":"Write_date",
"field_logic_name":"最后更新时间",
"entity_name":"Delivery_carrier",
"field_type":"DATETIME",
"nullable":1,
"physical_field":1,
"data_type":"DATETIME",
"key_field":0,
"show_order":1000,
"major_field":0
},
{
"fieldname":"IS_PUBLISHED" ,
"codename":"Is_published",
"field_logic_name":"是否公开",
"entity_name":"Delivery_carrier",
"field_type":"TRUEFALSE",
"nullable":1,
"physical_field":1,
"data_type":"BIT",
"key_field":0,
"show_order":1000,
"major_field":0
},
{
"fieldname":"WRITE_UID" ,
"codename":"Write_uid",
"field_logic_name":"ID",
"entity_name":"Delivery_carrier",
"ref_de":"RES_USERS",
"ref_field_name":"ID",
"relation_name":"DER1N_DELIVERY_CARRIER_RES_USERS_WRITE_UID",
"relation_codename":"Odoo_write",
"field_type":"PICKUP",
"nullable":1,
"physical_field":1,
"data_type":"BIGINT",
"key_field":0,
"show_order":1000,
"major_field":0
},
{
"fieldname":"CREATE_UID" ,
"codename":"Create_uid",
"field_logic_name":"ID",
"entity_name":"Delivery_carrier",
"ref_de":"RES_USERS",
"ref_field_name":"ID",
"relation_name":"DER1N_DELIVERY_CARRIER_RES_USERS_CREATE_UID",
"relation_codename":"Odoo_create",
"field_type":"PICKUP",
"nullable":1,
"physical_field":1,
"data_type":"BIGINT",
"key_field":0,
"show_order":1000,
"major_field":0
},
{
"fieldname":"WRITE_UNAME" ,
"codename":"Write_uname",
"field_logic_name":"名称",
"entity_name":"Delivery_carrier",
"ref_de":"RES_USERS",
"ref_field_name":"NAME",
"relation_name":"DER1N_DELIVERY_CARRIER_RES_USERS_WRITE_UID",
"relation_codename":"Odoo_write",
"field_type":"PICKUPTEXT",
"nullable":1,
"physical_field":0,
"data_type":"VARCHAR",
"data_length":100,
"key_field":0,
"show_order":1000,
"major_field":0
},
{
"fieldname":"CREATE_UNAME" ,
"codename":"Create_uname",
"field_logic_name":"名称",
"entity_name":"Delivery_carrier",
"ref_de":"RES_USERS",
"ref_field_name":"NAME",
"relation_name":"DER1N_DELIVERY_CARRIER_RES_USERS_CREATE_UID",
"relation_codename":"Odoo_create",
"field_type":"PICKUPTEXT",
"nullable":1,
"physical_field":0,
"data_type":"VARCHAR",
"data_length":100,
"key_field":0,
"show_order":1000,
"major_field":0
}
],
"subEntitys":[
{"name":"DER1N_RES_SUPPLIER_DELIVERY_CARRIER_PROPERTY_DELIVERY_CARRIER_ID",
"relation_type":"DER1N",
"code_name":"Odoo_delivery_carrier",
"entity_name":"RES_SUPPLIER",
"ref_entity_name":"DELIVERY_CARRIER"
}
],
"parentEntitys":[
{"name":"DER1N_DELIVERY_CARRIER_PRODUCT_PRODUCT_PRODUCT_ID",
"relation_type":"DER1N",
"code_name":"Odoo_product",
"entity_name":"DELIVERY_CARRIER",
"ref_entity_name":"PRODUCT_PRODUCT"
},
{"name":"DER1N_DELIVERY_CARRIER_RES_COMPANY_COMPANY_ID",
"relation_type":"DER1N",
"code_name":"Odoo_company",
"entity_name":"DELIVERY_CARRIER",
"ref_entity_name":"RES_COMPANY"
},
{"name":"DER1N_DELIVERY_CARRIER_RES_USERS_CREATE_UID",
"relation_type":"DER1N",
"code_name":"Odoo_create",
"entity_name":"DELIVERY_CARRIER",
"ref_entity_name":"RES_USERS"
},
{"name":"DER1N_DELIVERY_CARRIER_RES_USERS_WRITE_UID",
"relation_type":"DER1N",
"code_name":"Odoo_write",
"entity_name":"DELIVERY_CARRIER",
"ref_entity_name":"RES_USERS"
}
]
}
,
{
......@@ -62045,10 +62509,10 @@
"codename":"Wage",
"field_logic_name":"工资",
"entity_name":"Hr_contract",
"field_type":"DECIMAL",
"field_type":"FLOAT",
"nullable":0,
"physical_field":1,
"data_type":"DECIMAL",
"data_type":"FLOAT",
"key_field":0,
"show_order":1000,
"major_field":0
......@@ -118979,6 +119443,12 @@
"entity_name":"REPAIR_ORDER",
"ref_entity_name":"PRODUCT_PRICELIST"
},
{"name":"DER1N_RES_SUPPLIER_PRODUCT_PRICELIST_PROPERTY_PRODUCT_PRICELIST",
"relation_type":"DER1N",
"code_name":"Odoo_pricelist",
"entity_name":"RES_SUPPLIER",
"ref_entity_name":"PRODUCT_PRICELIST"
},
{"name":"DER1N_SALE_ORDER__PRODUCT_PRICELIST__PRICELIST_ID",
"relation_type":"DER1N",
"code_name":"Odoo_pricelist",
......@@ -122472,6 +122942,12 @@
"entity_name":"ACCOUNT_MOVE_LINE",
"ref_entity_name":"PRODUCT_PRODUCT"
},
{"name":"DER1N_DELIVERY_CARRIER_PRODUCT_PRODUCT_PRODUCT_ID",
"relation_type":"DER1N",
"code_name":"Odoo_product",
"entity_name":"DELIVERY_CARRIER",
"ref_entity_name":"PRODUCT_PRODUCT"
},
{"name":"DER1N_EVENT_EVENT_TICKET__PRODUCT_PRODUCT__PRODUCT_ID",
"relation_type":"DER1N",
"code_name":"Odoo_product",
......@@ -140997,6 +141473,12 @@
"entity_name":"CRM_TEAM",
"ref_entity_name":"RES_COMPANY"
},
{"name":"DER1N_DELIVERY_CARRIER_RES_COMPANY_COMPANY_ID",
"relation_type":"DER1N",
"code_name":"Odoo_company",
"entity_name":"DELIVERY_CARRIER",
"ref_entity_name":"RES_COMPANY"
},
{"name":"DER1N_DIGEST_DIGEST__RES_COMPANY__COMPANY_ID",
"relation_type":"DER1N",
"code_name":"Odoo_company",
......@@ -146996,6 +147478,12 @@
"entity_name":"RES_PARTNER_BANK",
"ref_entity_name":"RES_CURRENCY"
},
{"name":"DER1N_RES_SUPPLIER_RES_CURRENCY_PROPERTY_PURCHASE_CURRENCY_ID",
"relation_type":"DER1N",
"code_name":"Odoo_currency",
"entity_name":"RES_SUPPLIER",
"ref_entity_name":"RES_CURRENCY"
},
{"name":"DER1N_SALE_ORDER_LINE__RES_CURRENCY__CURRENCY_ID",
"relation_type":"DER1N",
"code_name":"Odoo_currency",
......@@ -150831,6 +151319,12 @@
"entity_name":"RES_PARTNER",
"ref_entity_name":"RES_PARTNER"
},
{"name":"DER1N_RES_SUPPLIER_RES_PARTNER_PARENT_ID",
"relation_type":"DER1N",
"code_name":"Odoo_parent",
"entity_name":"RES_SUPPLIER",
"ref_entity_name":"RES_PARTNER"
},
{"name":"DER1N_RES_USERS__RES_PARTNER__PARTNER_ID",
"relation_type":"DER1N",
"code_name":"Odoo_partner",
......@@ -152916,6 +153410,385 @@
"key_field":0,
"show_order":1000,
"major_field":0
},
{
"fieldname":"PROPERTY_DELIVERY_CARRIER_ID" ,
"codename":"Property_delivery_carrier_id",
"field_logic_name":"交货方法",
"entity_name":"Res_supplier",
"ref_de":"DELIVERY_CARRIER",
"ref_field_name":"ID",
"relation_name":"DER1N_RES_SUPPLIER_DELIVERY_CARRIER_PROPERTY_DELIVERY_CARRIER_ID",
"relation_codename":"Odoo_delivery_carrier",
"field_type":"PICKUP",
"nullable":1,
"physical_field":0,
"data_type":"BIGINT",
"data_length":20,
"key_field":0,
"show_order":1000,
"major_field":0
},
{
"fieldname":"PROPERTY_DELIVERY_CARRIER_NAME" ,
"codename":"Property_delivery_carrier_name",
"field_logic_name":"交货方法",
"entity_name":"Res_supplier",
"ref_de":"DELIVERY_CARRIER",
"ref_field_name":"NAME",
"relation_name":"DER1N_RES_SUPPLIER_DELIVERY_CARRIER_PROPERTY_DELIVERY_CARRIER_ID",
"relation_codename":"Odoo_delivery_carrier",
"field_type":"PICKUPTEXT",
"nullable":1,
"physical_field":0,
"data_type":"VARCHAR",
"data_length":100,
"key_field":0,
"show_order":1000,
"major_field":0
},
{
"fieldname":"PROPERTY_PAYMENT_TERM_ID" ,
"codename":"Property_payment_term_id",
"field_logic_name":"销售付款条款",
"entity_name":"Res_supplier",
"ref_de":"ACCOUNT_PAYMENT_TERM",
"ref_field_name":"ID",
"relation_name":"DER1N_RES_SUPPLIER_ACCOUNT_PAYMENT_TERM_PROPERTY_PAYMENT_TERM_ID",
"relation_codename":"Odoo_account_payment_term",
"field_type":"PICKUP",
"nullable":1,
"physical_field":0,
"data_type":"BIGINT",
"key_field":0,
"show_order":1000,
"major_field":0
},
{
"fieldname":"PROPERTY_PAYMENT_TERM_NAME" ,
"codename":"Property_payment_term_name",
"field_logic_name":"付款条款",
"entity_name":"Res_supplier",
"ref_de":"ACCOUNT_PAYMENT_TERM",
"ref_field_name":"NAME",
"relation_name":"DER1N_RES_SUPPLIER_ACCOUNT_PAYMENT_TERM_PROPERTY_PAYMENT_TERM_ID",
"relation_codename":"Odoo_account_payment_term",
"field_type":"PICKUPTEXT",
"nullable":1,
"physical_field":0,
"data_type":"VARCHAR",
"data_length":100,
"key_field":0,
"show_order":1000,
"major_field":0
},
{
"fieldname":"PROPERTY_PURCHASE_CURRENCY_ID" ,
"codename":"Property_purchase_currency_id",
"field_logic_name":"供应商货币",
"entity_name":"Res_supplier",
"ref_de":"RES_CURRENCY",
"ref_field_name":"ID",
"relation_name":"DER1N_RES_SUPPLIER_RES_CURRENCY_PROPERTY_PURCHASE_CURRENCY_ID",
"relation_codename":"Odoo_currency",
"field_type":"PICKUP",
"nullable":1,
"physical_field":0,
"data_type":"BIGINT",
"key_field":0,
"show_order":1000,
"major_field":0
},
{
"fieldname":"PROPERTY_PURCHASE_CURRENCY_NAME" ,
"codename":"Property_purchase_currency_name",
"field_logic_name":"供应商货币",
"entity_name":"Res_supplier",
"ref_de":"RES_CURRENCY",
"ref_field_name":"NAME",
"relation_name":"DER1N_RES_SUPPLIER_RES_CURRENCY_PROPERTY_PURCHASE_CURRENCY_ID",
"relation_codename":"Odoo_currency",
"field_type":"PICKUPTEXT",
"nullable":1,
"physical_field":0,
"data_type":"VARCHAR",
"data_length":3,
"key_field":0,
"show_order":1000,
"major_field":0
},
{
"fieldname":"PROPERTY_ACCOUNT_POSITION_ID" ,
"codename":"Property_account_position_id",
"field_logic_name":"税科目调整",
"entity_name":"Res_supplier",
"ref_de":"ACCOUNT_FISCAL_POSITION",
"ref_field_name":"ID",
"relation_name":"DER1N_RES_SUPPLIER_ACCOUNT_FISCAL_POSITION_PROPERTY_ACCOUNT_POSITION_ID",
"relation_codename":"Odoo_account_position",
"field_type":"PICKUP",
"nullable":1,
"physical_field":0,
"data_type":"BIGINT",
"key_field":0,
"show_order":1000,
"major_field":0
},
{
"fieldname":"PROPERTY_ACCOUNT_POSITION_NAME" ,
"codename":"Property_account_position_name",
"field_logic_name":"税科目调整",
"entity_name":"Res_supplier",
"ref_de":"ACCOUNT_FISCAL_POSITION",
"ref_field_name":"NAME",
"relation_name":"DER1N_RES_SUPPLIER_ACCOUNT_FISCAL_POSITION_PROPERTY_ACCOUNT_POSITION_ID",
"relation_codename":"Odoo_account_position",
"field_type":"PICKUPTEXT",
"nullable":1,
"physical_field":0,
"data_type":"VARCHAR",
"data_length":100,
"key_field":0,
"show_order":1000,
"major_field":0
},
{
"fieldname":"PROPERTY_STOCK_CUSTOMER" ,
"codename":"Property_stock_customer",
"field_logic_name":"客户位置",
"entity_name":"Res_supplier",
"ref_de":"STOCK_LOCATION",
"ref_field_name":"ID",
"relation_name":"DER1N_RES_SUPPLIER_STOCK_LOCATION_PROPERTY_STOCK_CUSTOMER",
"relation_codename":"Odoo_customer_location",
"field_type":"PICKUP",
"nullable":1,
"physical_field":0,
"data_type":"BIGINT",
"key_field":0,
"show_order":1000,
"major_field":0
},
{
"fieldname":"PROPERTY_STOCK_CUSTOMER_NAME" ,
"codename":"Property_stock_customer_name",
"field_logic_name":"客户位置",
"entity_name":"Res_supplier",
"ref_de":"STOCK_LOCATION",
"ref_field_name":"NAME",
"relation_name":"DER1N_RES_SUPPLIER_STOCK_LOCATION_PROPERTY_STOCK_CUSTOMER",
"relation_codename":"Odoo_customer_location",
"field_type":"PICKUPTEXT",
"nullable":1,
"physical_field":0,
"data_type":"VARCHAR",
"data_length":100,
"key_field":0,
"show_order":1000,
"major_field":0
},
{
"fieldname":"PROPERTY_STOCK_SUPPLIER" ,
"codename":"Property_stock_supplier",
"field_logic_name":"供应商位置",
"entity_name":"Res_supplier",
"ref_de":"STOCK_LOCATION",
"ref_field_name":"ID",
"relation_name":"DER1N_RES_SUPPLIER_STOCK_LOCATION_PROPERTY_STOCK_SUPPLIER",
"relation_codename":"Odoo_vendor_location",
"field_type":"PICKUP",
"nullable":1,
"physical_field":0,
"data_type":"BIGINT",
"key_field":0,
"show_order":1000,
"major_field":0
},
{
"fieldname":"PROPERTY_STOCK_SUPPLIER_NAME" ,
"codename":"Property_stock_supplier_name",
"field_logic_name":"供应商位置",
"entity_name":"Res_supplier",
"ref_de":"STOCK_LOCATION",
"ref_field_name":"NAME",
"relation_name":"DER1N_RES_SUPPLIER_STOCK_LOCATION_PROPERTY_STOCK_SUPPLIER",
"relation_codename":"Odoo_vendor_location",
"field_type":"PICKUPTEXT",
"nullable":1,
"physical_field":0,
"data_type":"VARCHAR",
"data_length":100,
"key_field":0,
"show_order":1000,
"major_field":0
},
{
"fieldname":"PROPERTY_STOCK_SUBCONTRACTOR" ,
"codename":"Property_stock_subcontractor",
"field_logic_name":"分包商位置",
"entity_name":"Res_supplier",
"ref_de":"STOCK_LOCATION",
"ref_field_name":"ID",
"relation_name":"DER1N_RES_SUPPLIER_STOCK_LOCATION_PROPERTY_STOCK_SUBCONTRACTOR",
"relation_codename":"Odoo_subcontractor_location",
"field_type":"PICKUP",
"nullable":1,
"physical_field":0,
"data_type":"BIGINT",
"key_field":0,
"show_order":1000,
"major_field":0
},
{
"fieldname":"PROPERTY_STOCK_SUBCONTRACTOR_NAME" ,
"codename":"Property_stock_subcontractor_name",
"field_logic_name":"分包商位置",
"entity_name":"Res_supplier",
"ref_de":"STOCK_LOCATION",
"ref_field_name":"NAME",
"relation_name":"DER1N_RES_SUPPLIER_STOCK_LOCATION_PROPERTY_STOCK_SUBCONTRACTOR",
"relation_codename":"Odoo_subcontractor_location",
"field_type":"PICKUPTEXT",
"nullable":1,
"physical_field":0,
"data_type":"VARCHAR",
"data_length":100,
"key_field":0,
"show_order":1000,
"major_field":0
},
{
"fieldname":"USER_ID" ,
"codename":"User_id",
"field_logic_name":"销售员",
"entity_name":"Res_supplier",
"ref_de":"RES_USERS",
"ref_field_name":"ID",
"relation_name":"DER1N_RES_SUPPLIER_RES_USERS_USER_ID",
"relation_codename":"Odoo_user",
"field_type":"PICKUP",
"nullable":1,
"physical_field":1,
"data_type":"BIGINT",
"key_field":0,
"show_order":1000,
"major_field":0
},
{
"fieldname":"USER_NAME" ,
"codename":"User_name",
"field_logic_name":"销售员",
"entity_name":"Res_supplier",
"ref_de":"RES_USERS",
"ref_field_name":"NAME",
"relation_name":"DER1N_RES_SUPPLIER_RES_USERS_USER_ID",
"relation_codename":"Odoo_user",
"field_type":"PICKUPTEXT",
"nullable":1,
"physical_field":0,
"data_type":"VARCHAR",
"data_length":100,
"key_field":0,
"show_order":1000,
"major_field":0
},
{
"fieldname":"PROPERTY_PRODUCT_PRICELIST" ,
"codename":"Property_product_pricelist",
"field_logic_name":"价格表",
"entity_name":"Res_supplier",
"ref_de":"PRODUCT_PRICELIST",
"ref_field_name":"ID",
"relation_name":"DER1N_RES_SUPPLIER_PRODUCT_PRICELIST_PROPERTY_PRODUCT_PRICELIST",
"relation_codename":"Odoo_pricelist",
"field_type":"PICKUP",
"nullable":1,
"physical_field":0,
"data_type":"BIGINT",
"key_field":0,
"show_order":1000,
"major_field":0
},
{
"fieldname":"PROPERTY_PRODUCT_PRICELIST_NAME" ,
"codename":"Property_product_pricelist_name",
"field_logic_name":"价格表",
"entity_name":"Res_supplier",
"ref_de":"PRODUCT_PRICELIST",
"ref_field_name":"NAME",
"relation_name":"DER1N_RES_SUPPLIER_PRODUCT_PRICELIST_PROPERTY_PRODUCT_PRICELIST",
"relation_codename":"Odoo_pricelist",
"field_type":"PICKUPTEXT",
"nullable":1,
"physical_field":0,
"data_type":"VARCHAR",
"data_length":100,
"key_field":0,
"show_order":1000,
"major_field":0
},
{
"fieldname":"PARENT_ID" ,
"codename":"Parent_id",
"field_logic_name":"ID",
"entity_name":"Res_supplier",
"ref_de":"RES_PARTNER",
"ref_field_name":"ID",
"relation_name":"DER1N_RES_SUPPLIER_RES_PARTNER_PARENT_ID",
"relation_codename":"Odoo_parent",
"field_type":"PICKUP",
"nullable":1,
"physical_field":1,
"data_type":"BIGINT",
"key_field":0,
"show_order":1000,
"major_field":0
},
{
"fieldname":"PARENT_NAME" ,
"codename":"Parent_name",
"field_logic_name":"公司",
"entity_name":"Res_supplier",
"ref_de":"RES_PARTNER",
"ref_field_name":"NAME",
"relation_name":"DER1N_RES_SUPPLIER_RES_PARTNER_PARENT_ID",
"relation_codename":"Odoo_parent",
"field_type":"PICKUPTEXT",
"nullable":1,
"physical_field":0,
"data_type":"VARCHAR",
"data_length":100,
"key_field":0,
"show_order":1000,
"major_field":0
},
{
"fieldname":"BARCODE" ,
"codename":"Barcode",
"field_logic_name":"条码",
"entity_name":"Res_supplier",
"field_type":"TEXT",
"nullable":1,
"physical_field":1,
"data_type":"VARCHAR",
"data_length":100,
"key_field":0,
"show_order":1000,
"major_field":0
},
{
"fieldname":"REF" ,
"codename":"Ref",
"field_logic_name":"内部参考",
"entity_name":"Res_supplier",
"field_type":"TEXT",
"nullable":1,
"physical_field":1,
"data_type":"VARCHAR",
"data_length":100,
"key_field":0,
"show_order":1000,
"major_field":0
}
],
"subEntitys":[
......@@ -152945,12 +153818,36 @@
}
],
"parentEntitys":[
{"name":"DER1N_RES_SUPPLIER_ACCOUNT_FISCAL_POSITION_PROPERTY_ACCOUNT_POSITION_ID",
"relation_type":"DER1N",
"code_name":"Odoo_account_position",
"entity_name":"RES_SUPPLIER",
"ref_entity_name":"ACCOUNT_FISCAL_POSITION"
},
{"name":"DER1N_RES_SUPPLIER_ACCOUNT_PAYMENT_TERM_PROPERTY_PAYMENT_TERM_ID",
"relation_type":"DER1N",
"code_name":"Odoo_account_payment_term",
"entity_name":"RES_SUPPLIER",
"ref_entity_name":"ACCOUNT_PAYMENT_TERM"
},
{"name":"DER1N_RES_SUPPLIER_ACCOUNT_PAYMENT_TERM_PROPERTY_SUPPLIER_PAYMENT_TERM_ID",
"relation_type":"DER1N",
"code_name":"Odoo_purchase_payment_term",
"entity_name":"RES_SUPPLIER",
"ref_entity_name":"ACCOUNT_PAYMENT_TERM"
},
{"name":"DER1N_RES_SUPPLIER_DELIVERY_CARRIER_PROPERTY_DELIVERY_CARRIER_ID",
"relation_type":"DER1N",
"code_name":"Odoo_delivery_carrier",
"entity_name":"RES_SUPPLIER",
"ref_entity_name":"DELIVERY_CARRIER"
},
{"name":"DER1N_RES_SUPPLIER_PRODUCT_PRICELIST_PROPERTY_PRODUCT_PRICELIST",
"relation_type":"DER1N",
"code_name":"Odoo_pricelist",
"entity_name":"RES_SUPPLIER",
"ref_entity_name":"PRODUCT_PRICELIST"
},
{"name":"DER1N_RES_SUPPLIER_RES_COMPANY_COMPANY_ID",
"relation_type":"DER1N",
"code_name":"Odoo_company",
......@@ -152969,11 +153866,47 @@
"entity_name":"RES_SUPPLIER",
"ref_entity_name":"RES_COUNTRY_STATE"
},
{"name":"DER1N_RES_SUPPLIER_RES_CURRENCY_PROPERTY_PURCHASE_CURRENCY_ID",
"relation_type":"DER1N",
"code_name":"Odoo_currency",
"entity_name":"RES_SUPPLIER",
"ref_entity_name":"RES_CURRENCY"
},
{"name":"DER1N_RES_SUPPLIER_RES_PARTNER_PARENT_ID",
"relation_type":"DER1N",
"code_name":"Odoo_parent",
"entity_name":"RES_SUPPLIER",
"ref_entity_name":"RES_PARTNER"
},
{"name":"DER1N_RES_SUPPLIER_RES_PARTNER_TITLE_TITLE",
"relation_type":"DER1N",
"code_name":"Odoo_title",
"entity_name":"RES_SUPPLIER",
"ref_entity_name":"RES_PARTNER_TITLE"
},
{"name":"DER1N_RES_SUPPLIER_RES_USERS_USER_ID",
"relation_type":"DER1N",
"code_name":"Odoo_user",
"entity_name":"RES_SUPPLIER",
"ref_entity_name":"RES_USERS"
},
{"name":"DER1N_RES_SUPPLIER_STOCK_LOCATION_PROPERTY_STOCK_CUSTOMER",
"relation_type":"DER1N",
"code_name":"Odoo_customer_location",
"entity_name":"RES_SUPPLIER",
"ref_entity_name":"STOCK_LOCATION"
},
{"name":"DER1N_RES_SUPPLIER_STOCK_LOCATION_PROPERTY_STOCK_SUBCONTRACTOR",
"relation_type":"DER1N",
"code_name":"Odoo_subcontractor_location",
"entity_name":"RES_SUPPLIER",
"ref_entity_name":"STOCK_LOCATION"
},
{"name":"DER1N_RES_SUPPLIER_STOCK_LOCATION_PROPERTY_STOCK_SUPPLIER",
"relation_type":"DER1N",
"code_name":"Odoo_vendor_location",
"entity_name":"RES_SUPPLIER",
"ref_entity_name":"STOCK_LOCATION"
}
]
}
......@@ -157428,6 +158361,18 @@
"entity_name":"CRM_TEAM",
"ref_entity_name":"RES_USERS"
},
{"name":"DER1N_DELIVERY_CARRIER_RES_USERS_CREATE_UID",
"relation_type":"DER1N",
"code_name":"Odoo_create",
"entity_name":"DELIVERY_CARRIER",
"ref_entity_name":"RES_USERS"
},
{"name":"DER1N_DELIVERY_CARRIER_RES_USERS_WRITE_UID",
"relation_type":"DER1N",
"code_name":"Odoo_write",
"entity_name":"DELIVERY_CARRIER",
"ref_entity_name":"RES_USERS"
},
{"name":"DER1N_DIGEST_DIGEST__RES_USERS__CREATE_UID",
"relation_type":"DER1N",
"code_name":"Odoo_create",
......@@ -160104,6 +161049,12 @@
"entity_name":"RES_PARTNER",
"ref_entity_name":"RES_USERS"
},
{"name":"DER1N_RES_SUPPLIER_RES_USERS_USER_ID",
"relation_type":"DER1N",
"code_name":"Odoo_user",
"entity_name":"RES_SUPPLIER",
"ref_entity_name":"RES_USERS"
},
{"name":"DER1N_RES_USERS_LOG__RES_USERS__CREATE_UID",
"relation_type":"DER1N",
"code_name":"Odoo_create",
......@@ -173258,6 +174209,24 @@
"entity_name":"RES_COMPANY",
"ref_entity_name":"STOCK_LOCATION"
},
{"name":"DER1N_RES_SUPPLIER_STOCK_LOCATION_PROPERTY_STOCK_CUSTOMER",
"relation_type":"DER1N",
"code_name":"Odoo_customer_location",
"entity_name":"RES_SUPPLIER",
"ref_entity_name":"STOCK_LOCATION"
},
{"name":"DER1N_RES_SUPPLIER_STOCK_LOCATION_PROPERTY_STOCK_SUBCONTRACTOR",
"relation_type":"DER1N",
"code_name":"Odoo_subcontractor_location",
"entity_name":"RES_SUPPLIER",
"ref_entity_name":"STOCK_LOCATION"
},
{"name":"DER1N_RES_SUPPLIER_STOCK_LOCATION_PROPERTY_STOCK_SUPPLIER",
"relation_type":"DER1N",
"code_name":"Odoo_vendor_location",
"entity_name":"RES_SUPPLIER",
"ref_entity_name":"STOCK_LOCATION"
},
{"name":"DER1N_STOCK_CHANGE_PRODUCT_QTY__STOCK_LOCATION__LOCATION_ID",
"relation_type":"DER1N",
"code_name":"Odoo_location",
......@@ -143,7 +143,7 @@ public class Hr_contractDTO extends DTOBase implements Serializable {
@JSONField(name = "wage")
@JsonProperty("wage")
@NotNull(message = "[工资]不允许为空!")
private BigDecimal wage;
private Double wage;
/**
* 属性 [DATE_START]
......@@ -523,7 +523,7 @@ public class Hr_contractDTO extends DTOBase implements Serializable {
/**
* 设置 [WAGE]
*/
public void setWage(BigDecimal wage){
public void setWage(Double wage){
this.wage = wage ;
this.modify("wage",wage);
}
......
......@@ -216,6 +216,204 @@ public class Res_supplierDTO extends DTOBase implements Serializable {
@JsonSerialize(using = ToStringSerializer.class)
private Long stateId;
/**
* 属性 [PROPERTY_DELIVERY_CARRIER_ID]
*
*/
@JSONField(name = "property_delivery_carrier_id")
@JsonProperty("property_delivery_carrier_id")
@JsonSerialize(using = ToStringSerializer.class)
private Long propertyDeliveryCarrierId;
/**
* 属性 [PROPERTY_DELIVERY_CARRIER_NAME]
*
*/
@JSONField(name = "property_delivery_carrier_name")
@JsonProperty("property_delivery_carrier_name")
@Size(min = 0, max = 100, message = "内容长度必须小于等于[100]")
private String propertyDeliveryCarrierName;
/**
* 属性 [PROPERTY_PAYMENT_TERM_ID]
*
*/
@JSONField(name = "property_payment_term_id")
@JsonProperty("property_payment_term_id")
@JsonSerialize(using = ToStringSerializer.class)
private Long propertyPaymentTermId;
/**
* 属性 [PROPERTY_PAYMENT_TERM_NAME]
*
*/
@JSONField(name = "property_payment_term_name")
@JsonProperty("property_payment_term_name")
@Size(min = 0, max = 100, message = "内容长度必须小于等于[100]")
private String propertyPaymentTermName;
/**
* 属性 [PROPERTY_PURCHASE_CURRENCY_ID]
*
*/
@JSONField(name = "property_purchase_currency_id")
@JsonProperty("property_purchase_currency_id")
@JsonSerialize(using = ToStringSerializer.class)
private Long propertyPurchaseCurrencyId;
/**
* 属性 [PROPERTY_PURCHASE_CURRENCY_NAME]
*
*/
@JSONField(name = "property_purchase_currency_name")
@JsonProperty("property_purchase_currency_name")
@Size(min = 0, max = 3, message = "内容长度必须小于等于[3]")
private String propertyPurchaseCurrencyName;
/**
* 属性 [PROPERTY_ACCOUNT_POSITION_ID]
*
*/
@JSONField(name = "property_account_position_id")
@JsonProperty("property_account_position_id")
@JsonSerialize(using = ToStringSerializer.class)
private Long propertyAccountPositionId;
/**
* 属性 [PROPERTY_ACCOUNT_POSITION_NAME]
*
*/
@JSONField(name = "property_account_position_name")
@JsonProperty("property_account_position_name")
@Size(min = 0, max = 100, message = "内容长度必须小于等于[100]")
private String propertyAccountPositionName;
/**
* 属性 [PROPERTY_STOCK_CUSTOMER]
*
*/
@JSONField(name = "property_stock_customer")
@JsonProperty("property_stock_customer")
@JsonSerialize(using = ToStringSerializer.class)
private Long propertyStockCustomer;
/**
* 属性 [PROPERTY_STOCK_CUSTOMER_NAME]
*
*/
@JSONField(name = "property_stock_customer_name")
@JsonProperty("property_stock_customer_name")
@Size(min = 0, max = 100, message = "内容长度必须小于等于[100]")
private String propertyStockCustomerName;
/**
* 属性 [PROPERTY_STOCK_SUPPLIER]
*
*/
@JSONField(name = "property_stock_supplier")
@JsonProperty("property_stock_supplier")
@JsonSerialize(using = ToStringSerializer.class)
private Long propertyStockSupplier;
/**
* 属性 [PROPERTY_STOCK_SUPPLIER_NAME]
*
*/
@JSONField(name = "property_stock_supplier_name")
@JsonProperty("property_stock_supplier_name")
@Size(min = 0, max = 100, message = "内容长度必须小于等于[100]")
private String propertyStockSupplierName;
/**
* 属性 [PROPERTY_STOCK_SUBCONTRACTOR]
*
*/
@JSONField(name = "property_stock_subcontractor")
@JsonProperty("property_stock_subcontractor")
@JsonSerialize(using = ToStringSerializer.class)
private Long propertyStockSubcontractor;
/**
* 属性 [PROPERTY_STOCK_SUBCONTRACTOR_NAME]
*
*/
@JSONField(name = "property_stock_subcontractor_name")
@JsonProperty("property_stock_subcontractor_name")
@Size(min = 0, max = 100, message = "内容长度必须小于等于[100]")
private String propertyStockSubcontractorName;
/**
* 属性 [USER_ID]
*
*/
@JSONField(name = "user_id")
@JsonProperty("user_id")
@JsonSerialize(using = ToStringSerializer.class)
private Long userId;
/**
* 属性 [USER_NAME]
*
*/
@JSONField(name = "user_name")
@JsonProperty("user_name")
@Size(min = 0, max = 100, message = "内容长度必须小于等于[100]")
private String userName;
/**
* 属性 [PROPERTY_PRODUCT_PRICELIST]
*
*/
@JSONField(name = "property_product_pricelist")
@JsonProperty("property_product_pricelist")
@JsonSerialize(using = ToStringSerializer.class)
private Long propertyProductPricelist;
/**
* 属性 [PROPERTY_PRODUCT_PRICELIST_NAME]
*
*/
@JSONField(name = "property_product_pricelist_name")
@JsonProperty("property_product_pricelist_name")
@Size(min = 0, max = 100, message = "内容长度必须小于等于[100]")
private String propertyProductPricelistName;
/**
* 属性 [PARENT_ID]
*
*/
@JSONField(name = "parent_id")
@JsonProperty("parent_id")
@JsonSerialize(using = ToStringSerializer.class)
private Long parentId;
/**
* 属性 [PARENT_NAME]
*
*/
@JSONField(name = "parent_name")
@JsonProperty("parent_name")
@Size(min = 0, max = 100, message = "内容长度必须小于等于[100]")
private String parentName;
/**
* 属性 [BARCODE]
*
*/
@JSONField(name = "barcode")
@JsonProperty("barcode")
@Size(min = 0, max = 100, message = "内容长度必须小于等于[100]")
private String barcode;
/**
* 属性 [REF]
*
*/
@JSONField(name = "ref")
@JsonProperty("ref")
@Size(min = 0, max = 100, message = "内容长度必须小于等于[100]")
private String ref;
/**
* 设置 [NAME]
......@@ -321,6 +519,102 @@ public class Res_supplierDTO extends DTOBase implements Serializable {
this.modify("state_id",stateId);
}
/**
* 设置 [PROPERTY_DELIVERY_CARRIER_ID]
*/
public void setPropertyDeliveryCarrierId(Long propertyDeliveryCarrierId){
this.propertyDeliveryCarrierId = propertyDeliveryCarrierId ;
this.modify("property_delivery_carrier_id",propertyDeliveryCarrierId);
}
/**
* 设置 [PROPERTY_PAYMENT_TERM_ID]
*/
public void setPropertyPaymentTermId(Long propertyPaymentTermId){
this.propertyPaymentTermId = propertyPaymentTermId ;
this.modify("property_payment_term_id",propertyPaymentTermId);
}
/**
* 设置 [PROPERTY_PURCHASE_CURRENCY_ID]
*/
public void setPropertyPurchaseCurrencyId(Long propertyPurchaseCurrencyId){
this.propertyPurchaseCurrencyId = propertyPurchaseCurrencyId ;
this.modify("property_purchase_currency_id",propertyPurchaseCurrencyId);
}
/**
* 设置 [PROPERTY_ACCOUNT_POSITION_ID]
*/
public void setPropertyAccountPositionId(Long propertyAccountPositionId){
this.propertyAccountPositionId = propertyAccountPositionId ;
this.modify("property_account_position_id",propertyAccountPositionId);
}
/**
* 设置 [PROPERTY_STOCK_CUSTOMER]
*/
public void setPropertyStockCustomer(Long propertyStockCustomer){
this.propertyStockCustomer = propertyStockCustomer ;
this.modify("property_stock_customer",propertyStockCustomer);
}
/**
* 设置 [PROPERTY_STOCK_SUPPLIER]
*/
public void setPropertyStockSupplier(Long propertyStockSupplier){
this.propertyStockSupplier = propertyStockSupplier ;
this.modify("property_stock_supplier",propertyStockSupplier);
}
/**
* 设置 [PROPERTY_STOCK_SUBCONTRACTOR]
*/
public void setPropertyStockSubcontractor(Long propertyStockSubcontractor){
this.propertyStockSubcontractor = propertyStockSubcontractor ;
this.modify("property_stock_subcontractor",propertyStockSubcontractor);
}
/**
* 设置 [USER_ID]
*/
public void setUserId(Long userId){
this.userId = userId ;
this.modify("user_id",userId);
}
/**
* 设置 [PROPERTY_PRODUCT_PRICELIST]
*/
public void setPropertyProductPricelist(Long propertyProductPricelist){
this.propertyProductPricelist = propertyProductPricelist ;
this.modify("property_product_pricelist",propertyProductPricelist);
}
/**
* 设置 [PARENT_ID]
*/
public void setParentId(Long parentId){
this.parentId = parentId ;
this.modify("parent_id",parentId);
}
/**
* 设置 [BARCODE]
*/
public void setBarcode(String barcode){
this.barcode = barcode ;
this.modify("barcode",barcode);
}
/**
* 设置 [REF]
*/
public void setRef(String ref){
this.ref = ref ;
this.modify("ref",ref);
}
}
......
......@@ -121,6 +121,16 @@ public class Res_config_settingsResource {
return ResponseEntity.status(HttpStatus.OK).body(res_config_settingsService.checkKey(res_config_settingsMapping.toDomain(res_config_settingsdto)));
}
@PreAuthorize("hasAnyAuthority('ROLE_SUPERADMIN','iBizBusinessCentral-Res_config_settings-Get_default-all')")
@ApiOperation(value = "获取配置", tags = {"配置设定" }, notes = "获取配置")
@RequestMapping(method = RequestMethod.GET, value = "/res_config_settings/get_default")
public ResponseEntity<Res_config_settingsDTO> get_default() {
Res_config_settings domain =new Res_config_settings();
domain = res_config_settingsService.get_default(domain);
Res_config_settingsDTO res_config_settingsdto = res_config_settingsMapping.toDto(domain);
return ResponseEntity.status(HttpStatus.OK).body(res_config_settingsdto);
}
@PreAuthorize("hasPermission(this.res_config_settingsMapping.toDomain(#res_config_settingsdto),'iBizBusinessCentral-Res_config_settings-Save')")
@ApiOperation(value = "保存配置设定", tags = {"配置设定" }, notes = "保存配置设定")
@RequestMapping(method = RequestMethod.POST, value = "/res_config_settings/save")
......
......@@ -8663,6 +8663,30 @@ public class StaticDict {
}
/**
* 代码表[合同状态快速分组]
*/
@Getter
public enum HR_CONTRACT__STATE_GridGrouping {
ALL("all","所有"),
DRAFT("draft","新建"),
OPEN("open","运行中"),
CLOSE("close","过期"),
CANCEL("cancel","已取消");
private String value;
private String text;
private String valueSeparator="";
private String textSeparator="";
private String emptyText="";
HR_CONTRACT__STATE_GridGrouping(String value , String text) {
this.value=value;
this.text = text;
}
}
/**
* 代码表[STOCK_PICKING_TYPE__CODE]
*/
......
Markdown 格式
0% or
您添加了 0 到此讨论。请谨慎行事。
先完成此消息的编辑!
想要评论请 注册