用DRF写数据接口;访问数据接口出现 ‘tuple’ object has no attribute ‘startswith’
```python
class Merchant(models.Model):
id = models.CharField(verbose_name='主键', db_column='MerchantId', primary_key=True, max_length=50,
default=UUIDTools.uuid4, editable=False)
name = models.CharField(verbose_name='商户名称', db_column='Name', max_length=50, blank=True, null=True)
short_name = models.CharField(verbose_name='商户简称', db_column='ShortName', max_length=50, blank=True, null=True)
license = models.CharField(verbose_name='烟草证号', db_column='License', max_length=50, blank=True, null=True)
channel = models.IntegerField(verbose_name='默认支付通道', db_column='Channel', max_length=255, blank=True, null=True)
class Meta:
app_label = 'app-payments',
db_table = 'pos_merchant',
verbose_name = '商户',
verbose_name_plural = verbose_name
原来是在通过一个内嵌类 “class Meta” 给你的 model 定义元数据时不需要加逗号(,)
``
`class Meta:
app_label = 'app-payments'
db_table = 'pos_merchant'
verbose_name = '商户'
verbose_name_plural = verbose_name