Guest User

Untitled

a guest
Mar 8th, 2018
30
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 3.39 KB | None | 0 0
  1. <dataConfig>
  2. <dataSource driver="com.mysql.jdbc.Driver" url="jdbc:mysql://localhost:3308/signcatch_sandbox_app2" user="root" password="123" />
  3. <document>
  4. <entity name="refund_orders"
  5. pk="id"
  6. query="select
  7. op.id,
  8. o.store_id,
  9. o.merchant_id,
  10. op.created_at as bill_date,
  11. o.refunded_order_no as original_order_no,
  12. o.order_id as refunded_orderid,
  13. op.sku as sku_code,
  14. op.batch_no as plu_code,
  15. op.product_name as description,
  16. op.quantity as qty,
  17. op.price as price,
  18. op.discount as discount,
  19. (op.pre_tax_amount+op.tax_amount) as amount,
  20. ml.location as pos_name,
  21. mm.first_name as user,
  22. o.manager_id as user_id,
  23. op.created_at,
  24. op.updated_at
  25. from order_product as op
  26. LEFT JOIN `order` o ON(o.order_id=op.order_no)
  27. LEFT JOIN merchant_manager mm ON(mm.id=o.manager_id)
  28. LEFT JOIN merchant_location ml ON(ml.id=o.merchant_location_id)
  29.  
  30. WHERE op.refund_order_id!=0
  31. GROUP BY op.id
  32. ORDER BY op.created_at ASC"
  33.  
  34. deltaImportQuery="
  35. SELECT
  36. op.id,
  37. o.store_id,
  38. o.merchant_id,
  39. op.created_at as bill_date,
  40. o.refunded_order_no as original_order_no,
  41. o.order_id as refunded_orderid,
  42. op.sku as sku_code,
  43. op.batch_no as plu_code,
  44. op.product_name as description,
  45. op.quantity as qty,
  46. op.price as price,
  47. op.discount as discount,
  48. (op.pre_tax_amount+op.tax_amount) as amount,
  49. ml.location as pos_name,
  50. mm.first_name as user,
  51. o.manager_id as user_id,
  52. op.created_at,
  53. op.updated_at
  54. from order_product as op
  55. LEFT JOIN `order` o ON(o.order_id=op.order_no)
  56. LEFT JOIN merchant_manager mm ON(mm.id=o.manager_id)
  57. LEFT JOIN merchant_location ml ON(ml.id=o.merchant_location_id)
  58.  
  59. WHERE op.refund_order_id!=0 AND op.id='${dih.delta.id}' "
  60.  
  61. deltaQuery="
  62. SELECT op.id as id
  63. FROM order_product as op
  64. WHERE op.refund_order_id!=0 AND op.updated_at>'${dih.delta.refund_orders.last_index_time}' "
  65. >
  66. <field column="id" name="id" />
  67. <field column="store_id" name="store_id" />
  68. <field column="merchant_id" name="merchant_id" />
  69. <field column="bill_date" name="bill_date" />
  70. <field column="original_order_no" name="original_order_no" />
  71. <field column="refunded_orderid" name="refunded_orderid" />
  72. <field column="sku_code" name="sku_code" />
  73. <field column="plu_code" name="plu_code" />
  74. <field column="description" name="description" />
  75. <field column="qty" name="qty" />
  76. <field column="price" name="price" />
  77. <field column="qty" name="qty" />
  78. <field column="discount" name="discount" />
  79. <field column="amount" name="amount" />
  80. <field column="pos_name" name="pos_name" />
  81. <field column="user" name="user" />
  82. <field column="user_id" name="user_id" />
  83. <field column="created_at" name="created_at" />
  84. <field column="updated_at" name="updated_at" />
  85. </entity>
  86. </document>
  87. </dataConfig>
Add Comment
Please, Sign In to add comment