xml version encoding UTF-8 backend model name project name class field

 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
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
<?xml version="1.0" encoding="UTF-8"?>
<backend>
<model>
<name>project</name>
<class>
<fields>
<field>
<name>id</name>
<type>protected</type>
<default>0</default>
</field>
<field>
<name>title</name>
<type>protected</type>
<default></default>
</field>
</fields>
<methods>
<method>
<comment>Some coment</comment>
<name>add_new</name>
<type>public</type>
<params>
<param>
<name>id</name>
<type>int</type>
</param>
<param>
<name>record</name>
<type>array</type>
</param>
</params>
<queries>
<query>SELECT id, title FROM `project` WHERE id = {id};</query>
<insert>
<table>project</table>
<where>id = {id}</where>
<data>record</data>
</insert>
<update>
<table>project</table>
<where>id = {id}</where>
<data>record</data>
</update>
</queries>
<return>QUERY_RESULT_ARRAY[1]</return>
</method>
</methods>
</class>
</model>
</backend>