mirror of
https://github.com/zhigang1992/rmq.git
synced 2026-04-30 21:52:33 +08:00
Fixed the table template, it wasn't using the reuse identifier when creating cells
This commit is contained in:
@@ -37,7 +37,7 @@ class <%= @name_camel_case %>Controller < UITableViewController
|
||||
data_row = @data[index_path.row]
|
||||
|
||||
cell = table_view.dequeueReusableCellWithIdentifier(<%= @name.upcase %>_CELL_ID) || begin
|
||||
rmq.create(<%= @name_camel_case %>Cell).get
|
||||
rmq.create(<%= @name_camel_case %>Cell, :<%= @name %>_cell, reuse_identifier: <%= @name.upcase %>_CELL_ID).get
|
||||
end
|
||||
|
||||
cell.update(data_row)
|
||||
|
||||
@@ -1,8 +1,6 @@
|
||||
class <%= @name_camel_case %>Cell < UITableViewCell
|
||||
|
||||
def rmq_build
|
||||
rmq(self).apply_style :<%= @name %>_cell
|
||||
|
||||
rmq(self.contentView).tap do |q|
|
||||
# Add your subviews, init stuff here
|
||||
# @foo = q.append(UILabel, :foo).get
|
||||
|
||||
Reference in New Issue
Block a user