Add new query
This commit is contained in:
@@ -0,0 +1 @@
|
||||
{"gitSyncId":"6978a0503f1cbf3622b556da_bb85ebfe-2773-4f11-880e-df88217f957d","id":"Sales - Units Ordered_units_ordered_by_series","pluginId":"postgres-plugin","pluginType":"DB","unpublishedAction":{"actionConfiguration":{"body":"SELECT \nCASE WHEN item_number IN ('16688','25020') THEN 'XR Series'\nWHEN item_number IN ('22351','24952') THEN 'SL Series'\nWHEN item_number IN ('17861','25021','29243','29752') THEN 'TS Series'\nWHEN item_number IN ('17862') THEN 'MS Series'\nWHEN item_number IN ('17863') THEN 'MT Series'\nWHEN item_number IN ('17873') THEN 'Harmonic Neutralizer'\n\nELSE 'None'\nEND AS \"Product\",\nROUND(SUM(coitem_qtyord),0) as \"Qty Ordered\"\nFROM coitem LEFT OUTER JOIN cohead ON cohead_id=coitem_cohead_id\nLEFT OUTER JOIN itemsite ON coitem_itemsite_id = itemsite_id\nLEFT OUTER JOIN item ON item_id = itemsite_item_id\nLEFT OUTER JOIN charass AS reportpower ON \n(coitem_id = reportpower.charass_target_id \nAND reportpower.charass_target_type = 'SI'\nAND reportpower.charass_char_id = 25)\nWHERE item_number IN ('16688','17861','17862','17863','22351','25020','25144','25147','25021','24952','17873','29243','29752')\nAND (coitem_status <> 'X') \nAND cohead_id NOT IN(SELECT cohead_id from rahead LEFT OUTER JOIN cohead ON rahead_new_cohead_id=cohead_id WHERE cohead_id IS NOT NULL)\nAND coitem_price != 0\nAND reportpower.charass_value IS NOT NULL\nAND (\n\tNULLIF('{{SeriesDateFrom.selectedDate}}','') IS NULL\n\tOR NULLIF('{{SeriesDateTo.selectedDate}}','') IS NULL\n\tOR cohead_orderdate BETWEEN\n\tNULLIF('{{SeriesDateFrom.selectedDate}}','')::date\n\tAND NULLIF('{{SeriesDateTo.selectedDate}}','')::date\n)\nGROUP BY \"Product\"\nORDER BY \"Product\"","encodeParamsToggle":true,"paginationType":"NONE","pluginSpecifiedTemplates":[{"value":true}],"timeoutInMillisecond":10000},"confirmBeforeExecute":false,"datasource":{"id":"xTuple_Sandbox","isAutoGenerated":false,"name":"xTuple_Sandbox","pluginId":"postgres-plugin"},"dynamicBindingPathList":[{"key":"body"}],"name":"units_ordered_by_series","pageId":"Sales - Units Ordered","runBehaviour":"AUTOMATIC","userSetOnLoad":false}}
|
||||
@@ -14,8 +14,8 @@ LEFT OUTER JOIN itemsite ON coitem_itemsite_id = itemsite_id
|
||||
LEFT OUTER JOIN item ON item_id = itemsite_item_id
|
||||
LEFT OUTER JOIN charass AS reportpower ON
|
||||
(coitem_id = reportpower.charass_target_id
|
||||
AND reportpower.charass_target_type = 'SI'
|
||||
AND reportpower.charass_char_id = 25)
|
||||
AND reportpower.charass_target_type = 'SI'
|
||||
AND reportpower.charass_char_id = 25)
|
||||
WHERE item_number IN ('16688','17861','17862','17863','22351','25020','25144','25147','25021','24952','17873','29243','29752')
|
||||
AND (coitem_status <> 'X')
|
||||
AND cohead_id NOT IN(SELECT cohead_id from rahead LEFT OUTER JOIN cohead ON rahead_new_cohead_id=cohead_id WHERE cohead_id IS NOT NULL)
|
||||
@@ -29,4 +29,4 @@ AND (
|
||||
AND NULLIF('{{SeriesDateTo.selectedDate}}','')::date
|
||||
)
|
||||
GROUP BY "Product"
|
||||
ORDER BY "Product"
|
||||
ORDER BY "Product"
|
||||
@@ -1,35 +0,0 @@
|
||||
{
|
||||
"gitSyncId": "6978a0503f1cbf3622b556da_bb85ebfe-2773-4f11-880e-df88217f957d",
|
||||
"id": "Sales - Units Ordered_units_shipped_by_series",
|
||||
"pluginId": "postgres-plugin",
|
||||
"pluginType": "DB",
|
||||
"unpublishedAction": {
|
||||
"actionConfiguration": {
|
||||
"body": "SELECT \nCASE WHEN item_number IN ('16688','25020') THEN 'XR Series'\nWHEN item_number IN ('22351','24952') THEN 'SL Series'\nWHEN item_number IN ('17861','25021','29243','29752') THEN 'TS Series'\nWHEN item_number IN ('17862') THEN 'MS Series'\nWHEN item_number IN ('17863') THEN 'MT Series'\nWHEN item_number IN ('17873') THEN 'Harmonic Neutralizer'\n\nELSE 'None'\nEND AS \"Product\",\nROUND(SUM(coitem_qtyord),0) as \"Qty Ordered\"\nFROM coitem LEFT OUTER JOIN cohead ON cohead_id=coitem_cohead_id\nLEFT OUTER JOIN itemsite ON coitem_itemsite_id = itemsite_id\nLEFT OUTER JOIN item ON item_id = itemsite_item_id\nLEFT OUTER JOIN charass AS reportpower ON \n(coitem_id = reportpower.charass_target_id \n AND reportpower.charass_target_type = 'SI'\n AND reportpower.charass_char_id = 25)\nWHERE item_number IN ('16688','17861','17862','17863','22351','25020','25144','25147','25021','24952','17873','29243','29752')\nAND (coitem_status <> 'X') \nAND cohead_id NOT IN(SELECT cohead_id from rahead LEFT OUTER JOIN cohead ON rahead_new_cohead_id=cohead_id WHERE cohead_id IS NOT NULL)\nAND coitem_price != 0\nAND reportpower.charass_value IS NOT NULL\nAND (\n\tNULLIF('{{SeriesDateFrom.selectedDate}}','') IS NULL\n\tOR NULLIF('{{SeriesDateTo.selectedDate}}','') IS NULL\n\tOR cohead_orderdate BETWEEN\n\tNULLIF('{{SeriesDateFrom.selectedDate}}','')::date\n\tAND NULLIF('{{SeriesDateTo.selectedDate}}','')::date\n)\nGROUP BY \"Product\"\nORDER BY \"Product\"",
|
||||
"encodeParamsToggle": true,
|
||||
"paginationType": "NONE",
|
||||
"pluginSpecifiedTemplates": [
|
||||
{
|
||||
"value": true
|
||||
}
|
||||
],
|
||||
"timeoutInMillisecond": 10000
|
||||
},
|
||||
"confirmBeforeExecute": false,
|
||||
"datasource": {
|
||||
"id": "xTuple_Sandbox",
|
||||
"isAutoGenerated": false,
|
||||
"name": "xTuple_Sandbox",
|
||||
"pluginId": "postgres-plugin"
|
||||
},
|
||||
"dynamicBindingPathList": [
|
||||
{
|
||||
"key": "body"
|
||||
}
|
||||
],
|
||||
"name": "units_shipped_by_series",
|
||||
"pageId": "Sales - Units Ordered",
|
||||
"runBehaviour": "AUTOMATIC",
|
||||
"userSetOnLoad": false
|
||||
}
|
||||
}
|
||||
@@ -174,7 +174,7 @@
|
||||
"responsiveBehavior": "fill",
|
||||
"rightColumn": 62,
|
||||
"searchKey": "",
|
||||
"tableData": "{{units_shipped_by_series.data}}",
|
||||
"tableData": "{{units_ordered_by_series.data}}",
|
||||
"textSize": "0.775rem",
|
||||
"topRow": 7,
|
||||
"totalRecordsCount": 0,
|
||||
|
||||
Reference in New Issue
Block a user