fixup! model template method
This commit is contained in:
		
							parent
							
								
									ea410df1e9
								
							
						
					
					
						commit
						dcb8efd90f
					
				| @ -196,25 +196,6 @@ function Template:__init__(template) | |||||||
| 	self.template = template | 	self.template = template | ||||||
| end | end | ||||||
| 
 | 
 | ||||||
| local Warning = class(Node) |  | ||||||
| M.Warning = Warning |  | ||||||
| 
 |  | ||||||
| function Warning:__init__(...) |  | ||||||
| 	Node.__init__(self, ...) |  | ||||||
| 
 |  | ||||||
| 	self.default   = nil |  | ||||||
| 	self.size      = nil |  | ||||||
| 	self.optional  = false |  | ||||||
| 
 |  | ||||||
| 	self.template  = "model/warning" |  | ||||||
| 
 |  | ||||||
| 	self.error = false |  | ||||||
| end |  | ||||||
| 
 |  | ||||||
| function Warning:setcontent(content) |  | ||||||
| 	self.content = content |  | ||||||
| end |  | ||||||
| 
 |  | ||||||
| local AbstractValue = class(Node) | local AbstractValue = class(Node) | ||||||
| M.AbstractValue = AbstractValue | M.AbstractValue = AbstractValue | ||||||
| 
 | 
 | ||||||
| @ -445,6 +426,11 @@ function Section:option(t, ...) | |||||||
| 	return obj | 	return obj | ||||||
| end | end | ||||||
| 
 | 
 | ||||||
|  | function Section:template(...) | ||||||
|  | 	local obj  = Template(...) | ||||||
|  | 	self:append(obj) | ||||||
|  | 	return obj | ||||||
|  | end | ||||||
| 
 | 
 | ||||||
| local Form = class(Node) | local Form = class(Node) | ||||||
| M.Form = Form | M.Form = Form | ||||||
|  | |||||||
		Loading…
	
		Reference in New Issue
	
	Block a user