Blame view

lib/syspro/business_objects/schemas/comfnd.xml.erb 972 Bytes
0f29247c   Isaac Lewis   add comfch and co...
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
  <?xml version="1.0" encoding="Windows-1252"?>
  <Query xmlns:xsd="http://www.w3.org/2001/XMLSchema-instance" xsd:noNamespaceSchemaLocation="COMFND.XSD">
    <TableName><%= @table_name %></TableName>
    <ReturnRows><%= @return_rows %></ReturnRows>
    <Columns>
      <% for column in @columns %>
        <Column><%= column[:name] %></Column>
      <% end %>
    </Columns>
    <% unless @expressions.empty? %>
      <Where>
        <% for expression in @expressions %>
          <Expression>
            <OpenBracket>(</OpenBracket>
            <% unless expression[:andor].nil? %>
              <AndOr><%= expression[:andor] %></AndOr>
            <% end %>
            <Column><%= expression[:column] %></Column>
            <Condition><%= expression[:condition] %></Condition>
            <Value><%= expression[:value] %></Value>
            <CloseBracket>)</CloseBracket>
          </Expression>
        <% end %>
      </Where>
    <% end %>
    <OrderBy>
      <Column><%= @order_by %></Column>
    </OrderBy>
  </Query>