Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
D
dc-java
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
huluobin
dc-java
Commits
6a86ae03
Commit
6a86ae03
authored
Apr 10, 2020
by
yinyong
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
亚马逊费用拆分新增sku数量
parent
9c730b32
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
315 additions
and
16 deletions
+315
-16
DcBaseFinanceAmazonItem.java
.../com/bailuntec/domain/entity/DcBaseFinanceAmazonItem.java
+39
-1
DcBaseFinanceAmazonItemExample.java
...luntec/domain/example/DcBaseFinanceAmazonItemExample.java
+181
-0
DcBaseFinanceAmazonItemMapper.xml
...va/com/bailuntec/mapper/DcBaseFinanceAmazonItemMapper.xml
+94
-15
CalculateAmazonItemJob.java
...c/main/java/com/bailuntec/job/CalculateAmazonItemJob.java
+1
-0
No files found.
data-common/src/main/java/com/bailuntec/domain/entity/DcBaseFinanceAmazonItem.java
View file @
6a86ae03
...
@@ -4,6 +4,7 @@ import lombok.Data;
...
@@ -4,6 +4,7 @@ import lombok.Data;
import
java.math.BigDecimal
;
import
java.math.BigDecimal
;
import
java.time.LocalDate
;
import
java.time.LocalDate
;
import
java.time.LocalDateTime
;
@Data
@Data
public
class
DcBaseFinanceAmazonItem
{
public
class
DcBaseFinanceAmazonItem
{
...
@@ -100,6 +101,15 @@ public class DcBaseFinanceAmazonItem {
...
@@ -100,6 +101,15 @@ public class DcBaseFinanceAmazonItem {
/**
/**
*
*
* This field was generated by MyBatis Generator.
* This field was generated by MyBatis Generator.
* This field corresponds to the database column dc_base_finance_amazon_item.sku_count
*
* @mbg.generated
*/
private
Integer
skuCount
;
/**
*
* This field was generated by MyBatis Generator.
* This field corresponds to the database column dc_base_finance_amazon_item.sku_ratio
* This field corresponds to the database column dc_base_finance_amazon_item.sku_ratio
*
*
* @mbg.generated
* @mbg.generated
...
@@ -170,6 +180,24 @@ public class DcBaseFinanceAmazonItem {
...
@@ -170,6 +180,24 @@ public class DcBaseFinanceAmazonItem {
private
BigDecimal
exchangeRateUsd
;
private
BigDecimal
exchangeRateUsd
;
/**
/**
*
* This field was generated by MyBatis Generator.
* This field corresponds to the database column dc_base_finance_amazon_item.bj_create
*
* @mbg.generated
*/
private
LocalDateTime
bjCreate
;
/**
*
* This field was generated by MyBatis Generator.
* This field corresponds to the database column dc_base_finance_amazon_item.bj_modified
*
* @mbg.generated
*/
private
LocalDateTime
bjModified
;
/**
* This method was generated by MyBatis Generator.
* This method was generated by MyBatis Generator.
* This method corresponds to the database table dc_base_finance_amazon_item
* This method corresponds to the database table dc_base_finance_amazon_item
*
*
...
@@ -191,6 +219,7 @@ public class DcBaseFinanceAmazonItem {
...
@@ -191,6 +219,7 @@ public class DcBaseFinanceAmazonItem {
sb
.
append
(
", site="
).
append
(
site
);
sb
.
append
(
", site="
).
append
(
site
);
sb
.
append
(
", cost="
).
append
(
cost
);
sb
.
append
(
", cost="
).
append
(
cost
);
sb
.
append
(
", skuCost="
).
append
(
skuCost
);
sb
.
append
(
", skuCost="
).
append
(
skuCost
);
sb
.
append
(
", skuCount="
).
append
(
skuCount
);
sb
.
append
(
", skuRatio="
).
append
(
skuRatio
);
sb
.
append
(
", skuRatio="
).
append
(
skuRatio
);
sb
.
append
(
", reportDate="
).
append
(
reportDate
);
sb
.
append
(
", reportDate="
).
append
(
reportDate
);
sb
.
append
(
", asin="
).
append
(
asin
);
sb
.
append
(
", asin="
).
append
(
asin
);
...
@@ -199,6 +228,8 @@ public class DcBaseFinanceAmazonItem {
...
@@ -199,6 +228,8 @@ public class DcBaseFinanceAmazonItem {
sb
.
append
(
", companyId="
).
append
(
companyId
);
sb
.
append
(
", companyId="
).
append
(
companyId
);
sb
.
append
(
", exchangeRate="
).
append
(
exchangeRate
);
sb
.
append
(
", exchangeRate="
).
append
(
exchangeRate
);
sb
.
append
(
", exchangeRateUsd="
).
append
(
exchangeRateUsd
);
sb
.
append
(
", exchangeRateUsd="
).
append
(
exchangeRateUsd
);
sb
.
append
(
", bjCreate="
).
append
(
bjCreate
);
sb
.
append
(
", bjModified="
).
append
(
bjModified
);
sb
.
append
(
"]"
);
sb
.
append
(
"]"
);
return
sb
.
toString
();
return
sb
.
toString
();
}
}
...
@@ -231,6 +262,7 @@ public class DcBaseFinanceAmazonItem {
...
@@ -231,6 +262,7 @@ public class DcBaseFinanceAmazonItem {
&&
(
this
.
getSite
()
==
null
?
other
.
getSite
()
==
null
:
this
.
getSite
().
equals
(
other
.
getSite
()))
&&
(
this
.
getSite
()
==
null
?
other
.
getSite
()
==
null
:
this
.
getSite
().
equals
(
other
.
getSite
()))
&&
(
this
.
getCost
()
==
null
?
other
.
getCost
()
==
null
:
this
.
getCost
().
equals
(
other
.
getCost
()))
&&
(
this
.
getCost
()
==
null
?
other
.
getCost
()
==
null
:
this
.
getCost
().
equals
(
other
.
getCost
()))
&&
(
this
.
getSkuCost
()
==
null
?
other
.
getSkuCost
()
==
null
:
this
.
getSkuCost
().
equals
(
other
.
getSkuCost
()))
&&
(
this
.
getSkuCost
()
==
null
?
other
.
getSkuCost
()
==
null
:
this
.
getSkuCost
().
equals
(
other
.
getSkuCost
()))
&&
(
this
.
getSkuCount
()
==
null
?
other
.
getSkuCount
()
==
null
:
this
.
getSkuCount
().
equals
(
other
.
getSkuCount
()))
&&
(
this
.
getSkuRatio
()
==
null
?
other
.
getSkuRatio
()
==
null
:
this
.
getSkuRatio
().
equals
(
other
.
getSkuRatio
()))
&&
(
this
.
getSkuRatio
()
==
null
?
other
.
getSkuRatio
()
==
null
:
this
.
getSkuRatio
().
equals
(
other
.
getSkuRatio
()))
&&
(
this
.
getReportDate
()
==
null
?
other
.
getReportDate
()
==
null
:
this
.
getReportDate
().
equals
(
other
.
getReportDate
()))
&&
(
this
.
getReportDate
()
==
null
?
other
.
getReportDate
()
==
null
:
this
.
getReportDate
().
equals
(
other
.
getReportDate
()))
&&
(
this
.
getAsin
()
==
null
?
other
.
getAsin
()
==
null
:
this
.
getAsin
().
equals
(
other
.
getAsin
()))
&&
(
this
.
getAsin
()
==
null
?
other
.
getAsin
()
==
null
:
this
.
getAsin
().
equals
(
other
.
getAsin
()))
...
@@ -238,7 +270,9 @@ public class DcBaseFinanceAmazonItem {
...
@@ -238,7 +270,9 @@ public class DcBaseFinanceAmazonItem {
&&
(
this
.
getAccountId
()
==
null
?
other
.
getAccountId
()
==
null
:
this
.
getAccountId
().
equals
(
other
.
getAccountId
()))
&&
(
this
.
getAccountId
()
==
null
?
other
.
getAccountId
()
==
null
:
this
.
getAccountId
().
equals
(
other
.
getAccountId
()))
&&
(
this
.
getCompanyId
()
==
null
?
other
.
getCompanyId
()
==
null
:
this
.
getCompanyId
().
equals
(
other
.
getCompanyId
()))
&&
(
this
.
getCompanyId
()
==
null
?
other
.
getCompanyId
()
==
null
:
this
.
getCompanyId
().
equals
(
other
.
getCompanyId
()))
&&
(
this
.
getExchangeRate
()
==
null
?
other
.
getExchangeRate
()
==
null
:
this
.
getExchangeRate
().
equals
(
other
.
getExchangeRate
()))
&&
(
this
.
getExchangeRate
()
==
null
?
other
.
getExchangeRate
()
==
null
:
this
.
getExchangeRate
().
equals
(
other
.
getExchangeRate
()))
&&
(
this
.
getExchangeRateUsd
()
==
null
?
other
.
getExchangeRateUsd
()
==
null
:
this
.
getExchangeRateUsd
().
equals
(
other
.
getExchangeRateUsd
()));
&&
(
this
.
getExchangeRateUsd
()
==
null
?
other
.
getExchangeRateUsd
()
==
null
:
this
.
getExchangeRateUsd
().
equals
(
other
.
getExchangeRateUsd
()))
&&
(
this
.
getBjCreate
()
==
null
?
other
.
getBjCreate
()
==
null
:
this
.
getBjCreate
().
equals
(
other
.
getBjCreate
()))
&&
(
this
.
getBjModified
()
==
null
?
other
.
getBjModified
()
==
null
:
this
.
getBjModified
().
equals
(
other
.
getBjModified
()));
}
}
/**
/**
...
@@ -261,6 +295,7 @@ public class DcBaseFinanceAmazonItem {
...
@@ -261,6 +295,7 @@ public class DcBaseFinanceAmazonItem {
result
=
prime
*
result
+
((
getSite
()
==
null
)
?
0
:
getSite
().
hashCode
());
result
=
prime
*
result
+
((
getSite
()
==
null
)
?
0
:
getSite
().
hashCode
());
result
=
prime
*
result
+
((
getCost
()
==
null
)
?
0
:
getCost
().
hashCode
());
result
=
prime
*
result
+
((
getCost
()
==
null
)
?
0
:
getCost
().
hashCode
());
result
=
prime
*
result
+
((
getSkuCost
()
==
null
)
?
0
:
getSkuCost
().
hashCode
());
result
=
prime
*
result
+
((
getSkuCost
()
==
null
)
?
0
:
getSkuCost
().
hashCode
());
result
=
prime
*
result
+
((
getSkuCount
()
==
null
)
?
0
:
getSkuCount
().
hashCode
());
result
=
prime
*
result
+
((
getSkuRatio
()
==
null
)
?
0
:
getSkuRatio
().
hashCode
());
result
=
prime
*
result
+
((
getSkuRatio
()
==
null
)
?
0
:
getSkuRatio
().
hashCode
());
result
=
prime
*
result
+
((
getReportDate
()
==
null
)
?
0
:
getReportDate
().
hashCode
());
result
=
prime
*
result
+
((
getReportDate
()
==
null
)
?
0
:
getReportDate
().
hashCode
());
result
=
prime
*
result
+
((
getAsin
()
==
null
)
?
0
:
getAsin
().
hashCode
());
result
=
prime
*
result
+
((
getAsin
()
==
null
)
?
0
:
getAsin
().
hashCode
());
...
@@ -269,6 +304,8 @@ public class DcBaseFinanceAmazonItem {
...
@@ -269,6 +304,8 @@ public class DcBaseFinanceAmazonItem {
result
=
prime
*
result
+
((
getCompanyId
()
==
null
)
?
0
:
getCompanyId
().
hashCode
());
result
=
prime
*
result
+
((
getCompanyId
()
==
null
)
?
0
:
getCompanyId
().
hashCode
());
result
=
prime
*
result
+
((
getExchangeRate
()
==
null
)
?
0
:
getExchangeRate
().
hashCode
());
result
=
prime
*
result
+
((
getExchangeRate
()
==
null
)
?
0
:
getExchangeRate
().
hashCode
());
result
=
prime
*
result
+
((
getExchangeRateUsd
()
==
null
)
?
0
:
getExchangeRateUsd
().
hashCode
());
result
=
prime
*
result
+
((
getExchangeRateUsd
()
==
null
)
?
0
:
getExchangeRateUsd
().
hashCode
());
result
=
prime
*
result
+
((
getBjCreate
()
==
null
)
?
0
:
getBjCreate
().
hashCode
());
result
=
prime
*
result
+
((
getBjModified
()
==
null
)
?
0
:
getBjModified
().
hashCode
());
return
result
;
return
result
;
}
}
}
}
\ No newline at end of file
data-common/src/main/java/com/bailuntec/domain/example/DcBaseFinanceAmazonItemExample.java
View file @
6a86ae03
...
@@ -2,6 +2,7 @@ package com.bailuntec.domain.example;
...
@@ -2,6 +2,7 @@ package com.bailuntec.domain.example;
import
java.math.BigDecimal
;
import
java.math.BigDecimal
;
import
java.time.LocalDate
;
import
java.time.LocalDate
;
import
java.time.LocalDateTime
;
import
java.util.ArrayList
;
import
java.util.ArrayList
;
import
java.util.List
;
import
java.util.List
;
...
@@ -1031,6 +1032,66 @@ public class DcBaseFinanceAmazonItemExample {
...
@@ -1031,6 +1032,66 @@ public class DcBaseFinanceAmazonItemExample {
return
(
Criteria
)
this
;
return
(
Criteria
)
this
;
}
}
public
Criteria
andSkuCountIsNull
()
{
addCriterion
(
"sku_count is null"
);
return
(
Criteria
)
this
;
}
public
Criteria
andSkuCountIsNotNull
()
{
addCriterion
(
"sku_count is not null"
);
return
(
Criteria
)
this
;
}
public
Criteria
andSkuCountEqualTo
(
Integer
value
)
{
addCriterion
(
"sku_count ="
,
value
,
"skuCount"
);
return
(
Criteria
)
this
;
}
public
Criteria
andSkuCountNotEqualTo
(
Integer
value
)
{
addCriterion
(
"sku_count <>"
,
value
,
"skuCount"
);
return
(
Criteria
)
this
;
}
public
Criteria
andSkuCountGreaterThan
(
Integer
value
)
{
addCriterion
(
"sku_count >"
,
value
,
"skuCount"
);
return
(
Criteria
)
this
;
}
public
Criteria
andSkuCountGreaterThanOrEqualTo
(
Integer
value
)
{
addCriterion
(
"sku_count >="
,
value
,
"skuCount"
);
return
(
Criteria
)
this
;
}
public
Criteria
andSkuCountLessThan
(
Integer
value
)
{
addCriterion
(
"sku_count <"
,
value
,
"skuCount"
);
return
(
Criteria
)
this
;
}
public
Criteria
andSkuCountLessThanOrEqualTo
(
Integer
value
)
{
addCriterion
(
"sku_count <="
,
value
,
"skuCount"
);
return
(
Criteria
)
this
;
}
public
Criteria
andSkuCountIn
(
List
<
Integer
>
values
)
{
addCriterion
(
"sku_count in"
,
values
,
"skuCount"
);
return
(
Criteria
)
this
;
}
public
Criteria
andSkuCountNotIn
(
List
<
Integer
>
values
)
{
addCriterion
(
"sku_count not in"
,
values
,
"skuCount"
);
return
(
Criteria
)
this
;
}
public
Criteria
andSkuCountBetween
(
Integer
value1
,
Integer
value2
)
{
addCriterion
(
"sku_count between"
,
value1
,
value2
,
"skuCount"
);
return
(
Criteria
)
this
;
}
public
Criteria
andSkuCountNotBetween
(
Integer
value1
,
Integer
value2
)
{
addCriterion
(
"sku_count not between"
,
value1
,
value2
,
"skuCount"
);
return
(
Criteria
)
this
;
}
public
Criteria
andSkuRatioIsNull
()
{
public
Criteria
andSkuRatioIsNull
()
{
addCriterion
(
"sku_ratio is null"
);
addCriterion
(
"sku_ratio is null"
);
return
(
Criteria
)
this
;
return
(
Criteria
)
this
;
...
@@ -1530,6 +1591,126 @@ public class DcBaseFinanceAmazonItemExample {
...
@@ -1530,6 +1591,126 @@ public class DcBaseFinanceAmazonItemExample {
addCriterion
(
"exchange_rate_usd not between"
,
value1
,
value2
,
"exchangeRateUsd"
);
addCriterion
(
"exchange_rate_usd not between"
,
value1
,
value2
,
"exchangeRateUsd"
);
return
(
Criteria
)
this
;
return
(
Criteria
)
this
;
}
}
public
Criteria
andBjCreateIsNull
()
{
addCriterion
(
"bj_create is null"
);
return
(
Criteria
)
this
;
}
public
Criteria
andBjCreateIsNotNull
()
{
addCriterion
(
"bj_create is not null"
);
return
(
Criteria
)
this
;
}
public
Criteria
andBjCreateEqualTo
(
LocalDateTime
value
)
{
addCriterion
(
"bj_create ="
,
value
,
"bjCreate"
);
return
(
Criteria
)
this
;
}
public
Criteria
andBjCreateNotEqualTo
(
LocalDateTime
value
)
{
addCriterion
(
"bj_create <>"
,
value
,
"bjCreate"
);
return
(
Criteria
)
this
;
}
public
Criteria
andBjCreateGreaterThan
(
LocalDateTime
value
)
{
addCriterion
(
"bj_create >"
,
value
,
"bjCreate"
);
return
(
Criteria
)
this
;
}
public
Criteria
andBjCreateGreaterThanOrEqualTo
(
LocalDateTime
value
)
{
addCriterion
(
"bj_create >="
,
value
,
"bjCreate"
);
return
(
Criteria
)
this
;
}
public
Criteria
andBjCreateLessThan
(
LocalDateTime
value
)
{
addCriterion
(
"bj_create <"
,
value
,
"bjCreate"
);
return
(
Criteria
)
this
;
}
public
Criteria
andBjCreateLessThanOrEqualTo
(
LocalDateTime
value
)
{
addCriterion
(
"bj_create <="
,
value
,
"bjCreate"
);
return
(
Criteria
)
this
;
}
public
Criteria
andBjCreateIn
(
List
<
LocalDateTime
>
values
)
{
addCriterion
(
"bj_create in"
,
values
,
"bjCreate"
);
return
(
Criteria
)
this
;
}
public
Criteria
andBjCreateNotIn
(
List
<
LocalDateTime
>
values
)
{
addCriterion
(
"bj_create not in"
,
values
,
"bjCreate"
);
return
(
Criteria
)
this
;
}
public
Criteria
andBjCreateBetween
(
LocalDateTime
value1
,
LocalDateTime
value2
)
{
addCriterion
(
"bj_create between"
,
value1
,
value2
,
"bjCreate"
);
return
(
Criteria
)
this
;
}
public
Criteria
andBjCreateNotBetween
(
LocalDateTime
value1
,
LocalDateTime
value2
)
{
addCriterion
(
"bj_create not between"
,
value1
,
value2
,
"bjCreate"
);
return
(
Criteria
)
this
;
}
public
Criteria
andBjModifiedIsNull
()
{
addCriterion
(
"bj_modified is null"
);
return
(
Criteria
)
this
;
}
public
Criteria
andBjModifiedIsNotNull
()
{
addCriterion
(
"bj_modified is not null"
);
return
(
Criteria
)
this
;
}
public
Criteria
andBjModifiedEqualTo
(
LocalDateTime
value
)
{
addCriterion
(
"bj_modified ="
,
value
,
"bjModified"
);
return
(
Criteria
)
this
;
}
public
Criteria
andBjModifiedNotEqualTo
(
LocalDateTime
value
)
{
addCriterion
(
"bj_modified <>"
,
value
,
"bjModified"
);
return
(
Criteria
)
this
;
}
public
Criteria
andBjModifiedGreaterThan
(
LocalDateTime
value
)
{
addCriterion
(
"bj_modified >"
,
value
,
"bjModified"
);
return
(
Criteria
)
this
;
}
public
Criteria
andBjModifiedGreaterThanOrEqualTo
(
LocalDateTime
value
)
{
addCriterion
(
"bj_modified >="
,
value
,
"bjModified"
);
return
(
Criteria
)
this
;
}
public
Criteria
andBjModifiedLessThan
(
LocalDateTime
value
)
{
addCriterion
(
"bj_modified <"
,
value
,
"bjModified"
);
return
(
Criteria
)
this
;
}
public
Criteria
andBjModifiedLessThanOrEqualTo
(
LocalDateTime
value
)
{
addCriterion
(
"bj_modified <="
,
value
,
"bjModified"
);
return
(
Criteria
)
this
;
}
public
Criteria
andBjModifiedIn
(
List
<
LocalDateTime
>
values
)
{
addCriterion
(
"bj_modified in"
,
values
,
"bjModified"
);
return
(
Criteria
)
this
;
}
public
Criteria
andBjModifiedNotIn
(
List
<
LocalDateTime
>
values
)
{
addCriterion
(
"bj_modified not in"
,
values
,
"bjModified"
);
return
(
Criteria
)
this
;
}
public
Criteria
andBjModifiedBetween
(
LocalDateTime
value1
,
LocalDateTime
value2
)
{
addCriterion
(
"bj_modified between"
,
value1
,
value2
,
"bjModified"
);
return
(
Criteria
)
this
;
}
public
Criteria
andBjModifiedNotBetween
(
LocalDateTime
value1
,
LocalDateTime
value2
)
{
addCriterion
(
"bj_modified not between"
,
value1
,
value2
,
"bjModified"
);
return
(
Criteria
)
this
;
}
}
}
/**
/**
...
...
data-common/src/main/java/com/bailuntec/mapper/DcBaseFinanceAmazonItemMapper.xml
View file @
6a86ae03
...
@@ -16,6 +16,7 @@
...
@@ -16,6 +16,7 @@
<result
column=
"site"
jdbcType=
"VARCHAR"
property=
"site"
/>
<result
column=
"site"
jdbcType=
"VARCHAR"
property=
"site"
/>
<result
column=
"cost"
jdbcType=
"DECIMAL"
property=
"cost"
/>
<result
column=
"cost"
jdbcType=
"DECIMAL"
property=
"cost"
/>
<result
column=
"sku_cost"
jdbcType=
"DECIMAL"
property=
"skuCost"
/>
<result
column=
"sku_cost"
jdbcType=
"DECIMAL"
property=
"skuCost"
/>
<result
column=
"sku_count"
jdbcType=
"INTEGER"
property=
"skuCount"
/>
<result
column=
"sku_ratio"
jdbcType=
"DECIMAL"
property=
"skuRatio"
/>
<result
column=
"sku_ratio"
jdbcType=
"DECIMAL"
property=
"skuRatio"
/>
<result
column=
"report_date"
jdbcType=
"DATE"
property=
"reportDate"
/>
<result
column=
"report_date"
jdbcType=
"DATE"
property=
"reportDate"
/>
<result
column=
"asin"
jdbcType=
"VARCHAR"
property=
"asin"
/>
<result
column=
"asin"
jdbcType=
"VARCHAR"
property=
"asin"
/>
...
@@ -24,6 +25,8 @@
...
@@ -24,6 +25,8 @@
<result
column=
"company_id"
jdbcType=
"INTEGER"
property=
"companyId"
/>
<result
column=
"company_id"
jdbcType=
"INTEGER"
property=
"companyId"
/>
<result
column=
"exchange_rate"
jdbcType=
"DECIMAL"
property=
"exchangeRate"
/>
<result
column=
"exchange_rate"
jdbcType=
"DECIMAL"
property=
"exchangeRate"
/>
<result
column=
"exchange_rate_usd"
jdbcType=
"DECIMAL"
property=
"exchangeRateUsd"
/>
<result
column=
"exchange_rate_usd"
jdbcType=
"DECIMAL"
property=
"exchangeRateUsd"
/>
<result
column=
"bj_create"
jdbcType=
"TIMESTAMP"
property=
"bjCreate"
/>
<result
column=
"bj_modified"
jdbcType=
"TIMESTAMP"
property=
"bjModified"
/>
</resultMap>
</resultMap>
<sql
id=
"Example_Where_Clause"
>
<sql
id=
"Example_Where_Clause"
>
<!--
<!--
...
@@ -97,7 +100,8 @@
...
@@ -97,7 +100,8 @@
This element is automatically generated by MyBatis Generator, do not modify.
This element is automatically generated by MyBatis Generator, do not modify.
-->
-->
id, amazon_id, campaign_id, ad_group_id, sku, item_id, bailun_sku, site, cost, sku_cost,
id, amazon_id, campaign_id, ad_group_id, sku, item_id, bailun_sku, site, cost, sku_cost,
sku_ratio, report_date, asin, currency, account_id, company_id, exchange_rate, exchange_rate_usd
sku_count, sku_ratio, report_date, asin, currency, account_id, company_id, exchange_rate,
exchange_rate_usd, bj_create, bj_modified
</sql>
</sql>
<select
id=
"selectByExample"
parameterType=
"com.bailuntec.domain.example.DcBaseFinanceAmazonItemExample"
resultMap=
"BaseResultMap"
>
<select
id=
"selectByExample"
parameterType=
"com.bailuntec.domain.example.DcBaseFinanceAmazonItemExample"
resultMap=
"BaseResultMap"
>
<!--
<!--
...
@@ -161,16 +165,18 @@
...
@@ -161,16 +165,18 @@
insert into dc_base_finance_amazon_item (id, amazon_id, campaign_id,
insert into dc_base_finance_amazon_item (id, amazon_id, campaign_id,
ad_group_id, sku, item_id,
ad_group_id, sku, item_id,
bailun_sku, site, cost,
bailun_sku, site, cost,
sku_cost, sku_ratio, report_date,
sku_cost, sku_count, sku_ratio,
asin, currency, account_id,
report_date, asin, currency,
company_id, exchange_rate, exchange_rate_usd
account_id, company_id, exchange_rate,
exchange_rate_usd, bj_create, bj_modified
)
)
values (#{id,jdbcType=INTEGER}, #{amazonId,jdbcType=INTEGER}, #{campaignId,jdbcType=VARCHAR},
values (#{id,jdbcType=INTEGER}, #{amazonId,jdbcType=INTEGER}, #{campaignId,jdbcType=VARCHAR},
#{adGroupId,jdbcType=VARCHAR}, #{sku,jdbcType=VARCHAR}, #{itemId,jdbcType=VARCHAR},
#{adGroupId,jdbcType=VARCHAR}, #{sku,jdbcType=VARCHAR}, #{itemId,jdbcType=VARCHAR},
#{bailunSku,jdbcType=VARCHAR}, #{site,jdbcType=VARCHAR}, #{cost,jdbcType=DECIMAL},
#{bailunSku,jdbcType=VARCHAR}, #{site,jdbcType=VARCHAR}, #{cost,jdbcType=DECIMAL},
#{skuCost,jdbcType=DECIMAL}, #{skuRatio,jdbcType=DECIMAL}, #{reportDate,jdbcType=DATE},
#{skuCost,jdbcType=DECIMAL}, #{skuCount,jdbcType=INTEGER}, #{skuRatio,jdbcType=DECIMAL},
#{asin,jdbcType=VARCHAR}, #{currency,jdbcType=VARCHAR}, #{accountId,jdbcType=INTEGER},
#{reportDate,jdbcType=DATE}, #{asin,jdbcType=VARCHAR}, #{currency,jdbcType=VARCHAR},
#{companyId,jdbcType=INTEGER}, #{exchangeRate,jdbcType=DECIMAL}, #{exchangeRateUsd,jdbcType=DECIMAL}
#{accountId,jdbcType=INTEGER}, #{companyId,jdbcType=INTEGER}, #{exchangeRate,jdbcType=DECIMAL},
#{exchangeRateUsd,jdbcType=DECIMAL}, #{bjCreate,jdbcType=TIMESTAMP}, #{bjModified,jdbcType=TIMESTAMP}
)
)
</insert>
</insert>
<insert
id=
"insertSelective"
parameterType=
"com.bailuntec.domain.entity.DcBaseFinanceAmazonItem"
>
<insert
id=
"insertSelective"
parameterType=
"com.bailuntec.domain.entity.DcBaseFinanceAmazonItem"
>
...
@@ -210,6 +216,9 @@
...
@@ -210,6 +216,9 @@
<if
test=
"skuCost != null"
>
<if
test=
"skuCost != null"
>
sku_cost,
sku_cost,
</if>
</if>
<if
test=
"skuCount != null"
>
sku_count,
</if>
<if
test=
"skuRatio != null"
>
<if
test=
"skuRatio != null"
>
sku_ratio,
sku_ratio,
</if>
</if>
...
@@ -234,6 +243,12 @@
...
@@ -234,6 +243,12 @@
<if
test=
"exchangeRateUsd != null"
>
<if
test=
"exchangeRateUsd != null"
>
exchange_rate_usd,
exchange_rate_usd,
</if>
</if>
<if
test=
"bjCreate != null"
>
bj_create,
</if>
<if
test=
"bjModified != null"
>
bj_modified,
</if>
</trim>
</trim>
<trim
prefix=
"values ("
suffix=
")"
suffixOverrides=
","
>
<trim
prefix=
"values ("
suffix=
")"
suffixOverrides=
","
>
<if
test=
"id != null"
>
<if
test=
"id != null"
>
...
@@ -266,6 +281,9 @@
...
@@ -266,6 +281,9 @@
<if
test=
"skuCost != null"
>
<if
test=
"skuCost != null"
>
#{skuCost,jdbcType=DECIMAL},
#{skuCost,jdbcType=DECIMAL},
</if>
</if>
<if
test=
"skuCount != null"
>
#{skuCount,jdbcType=INTEGER},
</if>
<if
test=
"skuRatio != null"
>
<if
test=
"skuRatio != null"
>
#{skuRatio,jdbcType=DECIMAL},
#{skuRatio,jdbcType=DECIMAL},
</if>
</if>
...
@@ -290,6 +308,12 @@
...
@@ -290,6 +308,12 @@
<if
test=
"exchangeRateUsd != null"
>
<if
test=
"exchangeRateUsd != null"
>
#{exchangeRateUsd,jdbcType=DECIMAL},
#{exchangeRateUsd,jdbcType=DECIMAL},
</if>
</if>
<if
test=
"bjCreate != null"
>
#{bjCreate,jdbcType=TIMESTAMP},
</if>
<if
test=
"bjModified != null"
>
#{bjModified,jdbcType=TIMESTAMP},
</if>
</trim>
</trim>
</insert>
</insert>
<select
id=
"countByExample"
parameterType=
"com.bailuntec.domain.example.DcBaseFinanceAmazonItemExample"
resultType=
"java.lang.Long"
>
<select
id=
"countByExample"
parameterType=
"com.bailuntec.domain.example.DcBaseFinanceAmazonItemExample"
resultType=
"java.lang.Long"
>
...
@@ -339,6 +363,9 @@
...
@@ -339,6 +363,9 @@
<if
test=
"record.skuCost != null"
>
<if
test=
"record.skuCost != null"
>
sku_cost = #{record.skuCost,jdbcType=DECIMAL},
sku_cost = #{record.skuCost,jdbcType=DECIMAL},
</if>
</if>
<if
test=
"record.skuCount != null"
>
sku_count = #{record.skuCount,jdbcType=INTEGER},
</if>
<if
test=
"record.skuRatio != null"
>
<if
test=
"record.skuRatio != null"
>
sku_ratio = #{record.skuRatio,jdbcType=DECIMAL},
sku_ratio = #{record.skuRatio,jdbcType=DECIMAL},
</if>
</if>
...
@@ -363,6 +390,12 @@
...
@@ -363,6 +390,12 @@
<if
test=
"record.exchangeRateUsd != null"
>
<if
test=
"record.exchangeRateUsd != null"
>
exchange_rate_usd = #{record.exchangeRateUsd,jdbcType=DECIMAL},
exchange_rate_usd = #{record.exchangeRateUsd,jdbcType=DECIMAL},
</if>
</if>
<if
test=
"record.bjCreate != null"
>
bj_create = #{record.bjCreate,jdbcType=TIMESTAMP},
</if>
<if
test=
"record.bjModified != null"
>
bj_modified = #{record.bjModified,jdbcType=TIMESTAMP},
</if>
</set>
</set>
<if
test=
"_parameter != null"
>
<if
test=
"_parameter != null"
>
<include
refid=
"Update_By_Example_Where_Clause"
/>
<include
refid=
"Update_By_Example_Where_Clause"
/>
...
@@ -384,6 +417,7 @@
...
@@ -384,6 +417,7 @@
site = #{record.site,jdbcType=VARCHAR},
site = #{record.site,jdbcType=VARCHAR},
cost = #{record.cost,jdbcType=DECIMAL},
cost = #{record.cost,jdbcType=DECIMAL},
sku_cost = #{record.skuCost,jdbcType=DECIMAL},
sku_cost = #{record.skuCost,jdbcType=DECIMAL},
sku_count = #{record.skuCount,jdbcType=INTEGER},
sku_ratio = #{record.skuRatio,jdbcType=DECIMAL},
sku_ratio = #{record.skuRatio,jdbcType=DECIMAL},
report_date = #{record.reportDate,jdbcType=DATE},
report_date = #{record.reportDate,jdbcType=DATE},
asin = #{record.asin,jdbcType=VARCHAR},
asin = #{record.asin,jdbcType=VARCHAR},
...
@@ -391,7 +425,9 @@
...
@@ -391,7 +425,9 @@
account_id = #{record.accountId,jdbcType=INTEGER},
account_id = #{record.accountId,jdbcType=INTEGER},
company_id = #{record.companyId,jdbcType=INTEGER},
company_id = #{record.companyId,jdbcType=INTEGER},
exchange_rate = #{record.exchangeRate,jdbcType=DECIMAL},
exchange_rate = #{record.exchangeRate,jdbcType=DECIMAL},
exchange_rate_usd = #{record.exchangeRateUsd,jdbcType=DECIMAL}
exchange_rate_usd = #{record.exchangeRateUsd,jdbcType=DECIMAL},
bj_create = #{record.bjCreate,jdbcType=TIMESTAMP},
bj_modified = #{record.bjModified,jdbcType=TIMESTAMP}
<if
test=
"_parameter != null"
>
<if
test=
"_parameter != null"
>
<include
refid=
"Update_By_Example_Where_Clause"
/>
<include
refid=
"Update_By_Example_Where_Clause"
/>
</if>
</if>
...
@@ -430,6 +466,9 @@
...
@@ -430,6 +466,9 @@
<if
test=
"skuCost != null"
>
<if
test=
"skuCost != null"
>
sku_cost = #{skuCost,jdbcType=DECIMAL},
sku_cost = #{skuCost,jdbcType=DECIMAL},
</if>
</if>
<if
test=
"skuCount != null"
>
sku_count = #{skuCount,jdbcType=INTEGER},
</if>
<if
test=
"skuRatio != null"
>
<if
test=
"skuRatio != null"
>
sku_ratio = #{skuRatio,jdbcType=DECIMAL},
sku_ratio = #{skuRatio,jdbcType=DECIMAL},
</if>
</if>
...
@@ -454,6 +493,12 @@
...
@@ -454,6 +493,12 @@
<if
test=
"exchangeRateUsd != null"
>
<if
test=
"exchangeRateUsd != null"
>
exchange_rate_usd = #{exchangeRateUsd,jdbcType=DECIMAL},
exchange_rate_usd = #{exchangeRateUsd,jdbcType=DECIMAL},
</if>
</if>
<if
test=
"bjCreate != null"
>
bj_create = #{bjCreate,jdbcType=TIMESTAMP},
</if>
<if
test=
"bjModified != null"
>
bj_modified = #{bjModified,jdbcType=TIMESTAMP},
</if>
</set>
</set>
where id = #{id,jdbcType=INTEGER}
where id = #{id,jdbcType=INTEGER}
</update>
</update>
...
@@ -472,6 +517,7 @@
...
@@ -472,6 +517,7 @@
site = #{site,jdbcType=VARCHAR},
site = #{site,jdbcType=VARCHAR},
cost = #{cost,jdbcType=DECIMAL},
cost = #{cost,jdbcType=DECIMAL},
sku_cost = #{skuCost,jdbcType=DECIMAL},
sku_cost = #{skuCost,jdbcType=DECIMAL},
sku_count = #{skuCount,jdbcType=INTEGER},
sku_ratio = #{skuRatio,jdbcType=DECIMAL},
sku_ratio = #{skuRatio,jdbcType=DECIMAL},
report_date = #{reportDate,jdbcType=DATE},
report_date = #{reportDate,jdbcType=DATE},
asin = #{asin,jdbcType=VARCHAR},
asin = #{asin,jdbcType=VARCHAR},
...
@@ -479,7 +525,9 @@
...
@@ -479,7 +525,9 @@
account_id = #{accountId,jdbcType=INTEGER},
account_id = #{accountId,jdbcType=INTEGER},
company_id = #{companyId,jdbcType=INTEGER},
company_id = #{companyId,jdbcType=INTEGER},
exchange_rate = #{exchangeRate,jdbcType=DECIMAL},
exchange_rate = #{exchangeRate,jdbcType=DECIMAL},
exchange_rate_usd = #{exchangeRateUsd,jdbcType=DECIMAL}
exchange_rate_usd = #{exchangeRateUsd,jdbcType=DECIMAL},
bj_create = #{bjCreate,jdbcType=TIMESTAMP},
bj_modified = #{bjModified,jdbcType=TIMESTAMP}
where id = #{id,jdbcType=INTEGER}
where id = #{id,jdbcType=INTEGER}
</update>
</update>
<insert
id=
"upsertSelective"
parameterType=
"com.bailuntec.domain.entity.DcBaseFinanceAmazonItem"
>
<insert
id=
"upsertSelective"
parameterType=
"com.bailuntec.domain.entity.DcBaseFinanceAmazonItem"
>
...
@@ -520,6 +568,9 @@
...
@@ -520,6 +568,9 @@
<if
test=
"skuCost != null"
>
<if
test=
"skuCost != null"
>
sku_cost,
sku_cost,
</if>
</if>
<if
test=
"skuCount != null"
>
sku_count,
</if>
<if
test=
"skuRatio != null"
>
<if
test=
"skuRatio != null"
>
sku_ratio,
sku_ratio,
</if>
</if>
...
@@ -544,6 +595,12 @@
...
@@ -544,6 +595,12 @@
<if
test=
"exchangeRateUsd != null"
>
<if
test=
"exchangeRateUsd != null"
>
exchange_rate_usd,
exchange_rate_usd,
</if>
</if>
<if
test=
"bjCreate != null"
>
bj_create,
</if>
<if
test=
"bjModified != null"
>
bj_modified,
</if>
</trim>
</trim>
values
values
<trim
prefix=
"("
suffix=
")"
suffixOverrides=
","
>
<trim
prefix=
"("
suffix=
")"
suffixOverrides=
","
>
...
@@ -577,6 +634,9 @@
...
@@ -577,6 +634,9 @@
<if
test=
"skuCost != null"
>
<if
test=
"skuCost != null"
>
#{skuCost,jdbcType=DECIMAL},
#{skuCost,jdbcType=DECIMAL},
</if>
</if>
<if
test=
"skuCount != null"
>
#{skuCount,jdbcType=INTEGER},
</if>
<if
test=
"skuRatio != null"
>
<if
test=
"skuRatio != null"
>
#{skuRatio,jdbcType=DECIMAL},
#{skuRatio,jdbcType=DECIMAL},
</if>
</if>
...
@@ -601,6 +661,12 @@
...
@@ -601,6 +661,12 @@
<if
test=
"exchangeRateUsd != null"
>
<if
test=
"exchangeRateUsd != null"
>
#{exchangeRateUsd,jdbcType=DECIMAL},
#{exchangeRateUsd,jdbcType=DECIMAL},
</if>
</if>
<if
test=
"bjCreate != null"
>
#{bjCreate,jdbcType=TIMESTAMP},
</if>
<if
test=
"bjModified != null"
>
#{bjModified,jdbcType=TIMESTAMP},
</if>
</trim>
</trim>
on duplicate key update
on duplicate key update
<trim
suffixOverrides=
","
>
<trim
suffixOverrides=
","
>
...
@@ -634,6 +700,9 @@
...
@@ -634,6 +700,9 @@
<if
test=
"skuCost != null"
>
<if
test=
"skuCost != null"
>
sku_cost = #{skuCost,jdbcType=DECIMAL},
sku_cost = #{skuCost,jdbcType=DECIMAL},
</if>
</if>
<if
test=
"skuCount != null"
>
sku_count = #{skuCount,jdbcType=INTEGER},
</if>
<if
test=
"skuRatio != null"
>
<if
test=
"skuRatio != null"
>
sku_ratio = #{skuRatio,jdbcType=DECIMAL},
sku_ratio = #{skuRatio,jdbcType=DECIMAL},
</if>
</if>
...
@@ -658,6 +727,12 @@
...
@@ -658,6 +727,12 @@
<if
test=
"exchangeRateUsd != null"
>
<if
test=
"exchangeRateUsd != null"
>
exchange_rate_usd = #{exchangeRateUsd,jdbcType=DECIMAL},
exchange_rate_usd = #{exchangeRateUsd,jdbcType=DECIMAL},
</if>
</if>
<if
test=
"bjCreate != null"
>
bj_create = #{bjCreate,jdbcType=TIMESTAMP},
</if>
<if
test=
"bjModified != null"
>
bj_modified = #{bjModified,jdbcType=TIMESTAMP},
</if>
</trim>
</trim>
</insert>
</insert>
<insert
id=
"upsert"
parameterType=
"com.bailuntec.domain.entity.DcBaseFinanceAmazonItem"
>
<insert
id=
"upsert"
parameterType=
"com.bailuntec.domain.entity.DcBaseFinanceAmazonItem"
>
...
@@ -668,15 +743,16 @@
...
@@ -668,15 +743,16 @@
-->
-->
insert into dc_base_finance_amazon_item
insert into dc_base_finance_amazon_item
(id, amazon_id, campaign_id, ad_group_id, sku, item_id, bailun_sku, site, cost, sku_cost,
(id, amazon_id, campaign_id, ad_group_id, sku, item_id, bailun_sku, site, cost, sku_cost,
sku_ratio, report_date, asin, currency, account_id, company_id, exchange_rate,
sku_
count, sku_
ratio, report_date, asin, currency, account_id, company_id, exchange_rate,
exchange_rate_usd)
exchange_rate_usd
, bj_create, bj_modified
)
values
values
(#{id,jdbcType=INTEGER}, #{amazonId,jdbcType=INTEGER}, #{campaignId,jdbcType=VARCHAR},
(#{id,jdbcType=INTEGER}, #{amazonId,jdbcType=INTEGER}, #{campaignId,jdbcType=VARCHAR},
#{adGroupId,jdbcType=VARCHAR}, #{sku,jdbcType=VARCHAR}, #{itemId,jdbcType=VARCHAR},
#{adGroupId,jdbcType=VARCHAR}, #{sku,jdbcType=VARCHAR}, #{itemId,jdbcType=VARCHAR},
#{bailunSku,jdbcType=VARCHAR}, #{site,jdbcType=VARCHAR}, #{cost,jdbcType=DECIMAL},
#{bailunSku,jdbcType=VARCHAR}, #{site,jdbcType=VARCHAR}, #{cost,jdbcType=DECIMAL},
#{skuCost,jdbcType=DECIMAL}, #{skuRatio,jdbcType=DECIMAL}, #{reportDate,jdbcType=DATE},
#{skuCost,jdbcType=DECIMAL}, #{skuCount,jdbcType=INTEGER}, #{skuRatio,jdbcType=DECIMAL},
#{asin,jdbcType=VARCHAR}, #{currency,jdbcType=VARCHAR}, #{accountId,jdbcType=INTEGER},
#{reportDate,jdbcType=DATE}, #{asin,jdbcType=VARCHAR}, #{currency,jdbcType=VARCHAR},
#{companyId,jdbcType=INTEGER}, #{exchangeRate,jdbcType=DECIMAL}, #{exchangeRateUsd,jdbcType=DECIMAL}
#{accountId,jdbcType=INTEGER}, #{companyId,jdbcType=INTEGER}, #{exchangeRate,jdbcType=DECIMAL},
#{exchangeRateUsd,jdbcType=DECIMAL}, #{bjCreate,jdbcType=TIMESTAMP}, #{bjModified,jdbcType=TIMESTAMP}
)
)
on duplicate key update
on duplicate key update
id = #{id,jdbcType=INTEGER},
id = #{id,jdbcType=INTEGER},
...
@@ -689,6 +765,7 @@
...
@@ -689,6 +765,7 @@
site = #{site,jdbcType=VARCHAR},
site = #{site,jdbcType=VARCHAR},
cost = #{cost,jdbcType=DECIMAL},
cost = #{cost,jdbcType=DECIMAL},
sku_cost = #{skuCost,jdbcType=DECIMAL},
sku_cost = #{skuCost,jdbcType=DECIMAL},
sku_count = #{skuCount,jdbcType=INTEGER},
sku_ratio = #{skuRatio,jdbcType=DECIMAL},
sku_ratio = #{skuRatio,jdbcType=DECIMAL},
report_date = #{reportDate,jdbcType=DATE},
report_date = #{reportDate,jdbcType=DATE},
asin = #{asin,jdbcType=VARCHAR},
asin = #{asin,jdbcType=VARCHAR},
...
@@ -696,7 +773,9 @@
...
@@ -696,7 +773,9 @@
account_id = #{accountId,jdbcType=INTEGER},
account_id = #{accountId,jdbcType=INTEGER},
company_id = #{companyId,jdbcType=INTEGER},
company_id = #{companyId,jdbcType=INTEGER},
exchange_rate = #{exchangeRate,jdbcType=DECIMAL},
exchange_rate = #{exchangeRate,jdbcType=DECIMAL},
exchange_rate_usd = #{exchangeRateUsd,jdbcType=DECIMAL}
exchange_rate_usd = #{exchangeRateUsd,jdbcType=DECIMAL},
bj_create = #{bjCreate,jdbcType=TIMESTAMP},
bj_modified = #{bjModified,jdbcType=TIMESTAMP}
</insert>
</insert>
<select
id=
"selectOneByExample"
parameterType=
"com.bailuntec.domain.example.DcBaseFinanceAmazonItemExample"
resultMap=
"BaseResultMap"
>
<select
id=
"selectOneByExample"
parameterType=
"com.bailuntec.domain.example.DcBaseFinanceAmazonItemExample"
resultMap=
"BaseResultMap"
>
<!--
<!--
...
...
data-mid/mid-calculate-item/src/main/java/com/bailuntec/job/CalculateAmazonItemJob.java
View file @
6a86ae03
...
@@ -70,6 +70,7 @@ public class CalculateAmazonItemJob extends PointJob {
...
@@ -70,6 +70,7 @@ public class CalculateAmazonItemJob extends PointJob {
dcBaseFinanceAmazonItem
.
setItemId
(
dcBaseSkuMappingItemDto
.
getItemId
());
dcBaseFinanceAmazonItem
.
setItemId
(
dcBaseSkuMappingItemDto
.
getItemId
());
dcBaseFinanceAmazonItem
.
setReportDate
(
dcBaseFinanceAmazonItemDto
.
getReportDate
());
dcBaseFinanceAmazonItem
.
setReportDate
(
dcBaseFinanceAmazonItemDto
.
getReportDate
());
dcBaseFinanceAmazonItem
.
setSkuCost
(
dcBaseFinanceAmazonItemDto
.
getCost
().
multiply
(
unitPriceRadio
));
dcBaseFinanceAmazonItem
.
setSkuCost
(
dcBaseFinanceAmazonItemDto
.
getCost
().
multiply
(
unitPriceRadio
));
dcBaseFinanceAmazonItem
.
setSkuCount
(
dcBaseSkuMappingItemDto
.
getCount
());
dcBaseFinanceAmazonItem
.
setSite
(
dcBaseFinanceAmazonItemDto
.
getSiteEn
());
dcBaseFinanceAmazonItem
.
setSite
(
dcBaseFinanceAmazonItemDto
.
getSiteEn
());
if
(
dcBaseFinanceAmazonItem
.
getBailunSku
()
==
null
)
{
if
(
dcBaseFinanceAmazonItem
.
getBailunSku
()
==
null
)
{
dcBaseFinanceAmazonItem
.
setBailunSku
(
"无"
);
dcBaseFinanceAmazonItem
.
setBailunSku
(
"无"
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment