|
|
@ -644,7 +644,8 @@ |
|
|
from PartSubPropertiesValueHeader a left join PropertiesModelDetail b on a.CodeNo=b.CodeNo |
|
|
from PartSubPropertiesValueHeader a left join PropertiesModelDetail b on a.CodeNo=b.CodeNo |
|
|
left join PartSubPropertiesValue c on c.Site=#{site} and c.PartNo=#{toolId} and c.RecordType='T' and b.ItemNo=c.ItemNo |
|
|
left join PartSubPropertiesValue c on c.Site=#{site} and c.PartNo=#{toolId} and c.RecordType='T' and b.ItemNo=c.ItemNo |
|
|
left join PropertiesItem e on b.PropertiesItemNo=e.ItemNo |
|
|
left join PropertiesItem e on b.PropertiesItemNo=e.ItemNo |
|
|
where c.ItemNo is null and a.RecordType='T' |
|
|
|
|
|
|
|
|
where c.ItemNo is null and a.RecordType='T' and a.PartNo=#{toolId} and a.site= #{site} |
|
|
|
|
|
|
|
|
</insert> |
|
|
</insert> |
|
|
|
|
|
|
|
|
<!-- 工具属性查询 --> |
|
|
<!-- 工具属性查询 --> |
|
|
@ -692,7 +693,7 @@ |
|
|
td.steelSeal, |
|
|
td.steelSeal, |
|
|
td.Price, |
|
|
td.Price, |
|
|
dbo.Get_AttributeValue(td.Site, td.ToolID, 'CUSTOMER') as customer, |
|
|
dbo.Get_AttributeValue(td.Site, td.ToolID, 'CUSTOMER') as customer, |
|
|
dbo.Get_AttributeValue(td.Site, td.ToolID, 'FETYONG') as contributor |
|
|
|
|
|
|
|
|
dbo.Get_AttributeValue(td.Site, td.ToolID, 'FEIYONG') as contributor |
|
|
FROM ToolDetail as td |
|
|
FROM ToolDetail as td |
|
|
LEFT JOIN ToolHeader as th ON td.ToolID = th.ToolID and td.Site = th.Site |
|
|
LEFT JOIN ToolHeader as th ON td.ToolID = th.ToolID and td.Site = th.Site |
|
|
LEFT JOIN Location as l ON td.LocationID = l.LocationID and td.Site = l.Site |
|
|
LEFT JOIN Location as l ON td.LocationID = l.LocationID and td.Site = l.Site |
|
|
@ -712,7 +713,7 @@ |
|
|
AND dbo.Get_AttributeValue(td.Site, td.ToolID, 'CUSTOMER') like #{query.customer} |
|
|
AND dbo.Get_AttributeValue(td.Site, td.ToolID, 'CUSTOMER') like #{query.customer} |
|
|
</if> |
|
|
</if> |
|
|
<if test="query.contributor != '' and query.contributor != null"> |
|
|
<if test="query.contributor != '' and query.contributor != null"> |
|
|
AND dbo.Get_AttributeValue(td.Site, td.ToolID, 'FETYONG') like #{query.contributor} |
|
|
|
|
|
|
|
|
AND dbo.Get_AttributeValue(td.Site, td.ToolID, 'FEIYONG') like #{query.contributor} |
|
|
</if> |
|
|
</if> |
|
|
<if test="query.startDate != null"> |
|
|
<if test="query.startDate != null"> |
|
|
AND td.PurchaseDate <![CDATA[ >= ]]> #{query.startDate} |
|
|
AND td.PurchaseDate <![CDATA[ >= ]]> #{query.startDate} |
|
|
|