class JobInfo(models.Model): com = models.ForeignKey(CompanyInfo, verbose_name='发布商家', blank=True, null=True) #title = models.CharField('标题',max_length=100) position = models.CharField('职位', max_length=100) #com_name = models.CharField('公司名称',max_length=200) address = models.CharField('上班地址', max_length=400, blank=True) #pay= models.CharField('薪酬待遇',max_length=100,blank=True) pay = models.IntegerField(verbose_name='支付费用', default=0) require_time = models.CharField('要求时间', max_length=100, blank=True) key_words = models.CharField('关键字', max_length=30, blank=True, help_text='最多不超过30个字') #contact = models.CharField('联系方式',max_length=200,) update_time = models.DateTimeField('更新时间', auto_now_add=True) detail = models.TextField('详细介绍', blank=True) #publisher = models.ForeignKey(User,) plat_contract = PictureField('服务合同', max_length=300, blank=True, help_text='请在[资料下载]中下载模板') contract = PictureField('合同', max_length=300, blank=True) bid = PictureField('中标书', max_length=300, blank=True) status = models.IntegerField('在线状态', choices=INFO_STATUS, default=1) audit_status = models.IntegerField('审批状态', choices=AUDIT_STATUS, default=1) appoint = models.ManyToManyField( to='WorkInfo', blank=True, verbose_name='指定工人' ) #models.ForeignKey('WorkInfo',verbose_name='指定工人',blank=True,null=True) admin_fee = models.IntegerField(verbose_name='管理费', default=0) def __str__(self): return self.position
class CompanyInfo(models.Model): user = models.OneToOneField(User, verbose_name='账号') name = models.CharField('公司名称', max_length=200) contact = models.CharField( '电话', max_length=200, ) address = models.CharField('公司地址', max_length=400, blank=True) license = PictureField('营业执照', blank=True, max_length=300) account_certificate = PictureField('开户许可证书', blank=True, max_length=300) opening_bank = models.CharField('开户行', blank=True, max_length=400) bank_code = models.CharField('银行账号', blank=True, max_length=300) website = models.CharField('网站', blank=True, max_length=400) qualification_certificate = PictureField('资质证书', blank=True, max_length=300) update_time = models.DateTimeField(verbose_name='更新时间', auto_now=True) status = models.IntegerField(verbose_name='当前状态', choices=COM_INFO_STATUS, default=0) def __str__(self): return self.name
class SourceImage(models.Model): tag_content = models.CharField('标签',max_length=300,blank=True) status = models.IntegerField('状态',default=0,choices=IMAGE_STATUS) url = PictureField('图片',max_length=200,blank=True) color_block = PictureField('色块',max_length=200,blank=True) thumbnail = PictureField('缩略图',max_length=200,blank=True) uploadtime = models.DateTimeField('上传日期',null=True,blank=True) resolution = models.CharField('分辨率',max_length=30,blank=True) size = models.CharField('大小',max_length=30,blank=True) def __str__(self): return str(self.id )
class ZhanXunModel(models.Model): title = models.CharField('标题',max_length=500) abstract = models.TextField('摘要',blank=True) cover = PictureField('封面',max_length=400,blank=True) content = models.TextField('内容',blank=True) status=models.IntegerField('状态',choices=ZHANXUN_STATUS,default=0) update_time =models.DateTimeField('更新时间',auto_now=True)
class Area(models.Model): label = models.CharField('显示名', max_length=100) pos = models.CharField('坐标', max_length=30, help_text='请严格按照 x,y 的格式填写') pic = PictureField('区域图', max_length=300, blank=True) def __str__(self): return self.label
class YewuRecomItem(models.Model): yewu = models.ForeignKey(Yewu, verbose_name='展示业务') recom_panel = models.ForeignKey(YewuRecomPanel, verbose_name='从属于') title = models.CharField('大标题', max_length=200) sub_title = models.CharField('小标题', max_length=300) price = models.CharField('价格', max_length=30) cover = PictureField('宣传图片', max_length=200, blank=True)
class FloorType(models.Model): label = models.CharField('户型名', max_length=30) img_2d = PictureField('2D图片', blank=True, max_length=300) img_3d = models.CharField('3D链接', blank=True, max_length=300) def __str__(self): return self.label
class Banner(models.Model): title = models.CharField('标题', max_length=500, blank=True) cover = PictureField('封面', max_length=300) status = models.IntegerField(verbose_name='在线', default=0, choices=ARTICLE_STATUS) order = models.IntegerField(verbose_name='排序', default=0) link = models.CharField('连接', max_length=200, blank=True)
class ImageGroup(models.Model): zh = models.CharField('中文名',max_length=200,) en = models.CharField('英文名',max_length=200,blank=True) status = models.IntegerField('状态',default=0,choices=IMAGE_STATUS) images = models.ManyToManyField(SourceImage,verbose_name='图片') cover = PictureField('图片',max_length=200,blank=True) def __str__(self): return self.zh
class Saler(models.Model): """销售人员""" name = models.CharField('人名', max_length=30) head = PictureField('头像', max_length=300, blank=True) phone = models.CharField('手机号码', max_length=50, blank=True) slogan = models.CharField('业务员口号', max_length=500, blank=True) exp = models.CharField('工作年限', max_length=30, blank=True) count = models.CharField('最近接单', max_length=30, blank=True) comment = models.CharField('好评率', max_length=30, blank=True)
class ExampleInfo(models.Model): title = models.CharField('标题', max_length=500) content = RichtextField('内容') cover = PictureField('封面', max_length=300, blank=True) status = models.IntegerField(verbose_name='在线', default=0, choices=ARTICLE_STATUS) kind = models.IntegerField(verbose_name='类别', default=0, choices=EXAMPLE_KIND)
class Dish(models.Model): label = models.CharField('菜名称',max_length=200,) cover = PictureField('封面',max_length = 300,) title = models.CharField('标题',max_length=300,blank=True) dsp = models.TextField('描述',blank=True) price = models.DecimalField('价格',max_digits=10,decimal_places=2,default=0) kind = models.IntegerField('种类',default=0,choices=DISH_KIND) key_word = models.CharField('关键字',max_length=300,blank=True) def __str__(self): return self.label
class ApplyRecord(models.Model): worker = models.ForeignKey(WorkInfo, verbose_name='求职者') job = models.ForeignKey(JobInfo, verbose_name='申请职位') status = models.IntegerField(verbose_name='状态', choices=APPLY_STATUS, default=0) finish_proof = PictureField('完结拍照', max_length=200, blank=True) updatetime = models.DateTimeField(verbose_name='更新时间', auto_now=True) createtime = models.DateTimeField(verbose_name='创建时间', auto_now_add=True) def __str__(self): return self.job.position + ' 申请'
class ZhanRich(models.Model): menu_label = models.CharField('菜单显示名', max_length=30, blank=True) label = models.CharField('大显示名', max_length=30, blank=True, help_text='显示位置,请参看demo页面') cover = PictureField('图片', max_length=300, blank=True) page = models.CharField('从属页面', max_length=30, blank=True, choices=PAGES) priority = models.IntegerField('优先级', default=0, help_text='大的排列在前') content = models.TextField('主要内容', blank=True) def __str__(self): return self.label
class Article(models.Model): title = models.CharField('标题', max_length=500) content = RichtextField('内容') cover = PictureField('封面', max_length=300, blank=True) status = models.IntegerField(verbose_name='在线', default=0, choices=ARTICLE_STATUS) #kind = models.IntegerField(verbose_name='类别',default=0,choices=ARTICLE_KIND) order = models.IntegerField(verbose_name='排序', default=0) tag = MultiChoiceField('标签', max_length=300, choices=ARTICLE_TAG, blank=True) recommend = models.BooleanField('推荐', default=False)
class TBEmployee(models.Model): name = models.CharField('员工姓名', max_length=100) no = models.CharField('工号', max_length=100, blank=True) gen = models.IntegerField(verbose_name='性别', default=0, choices=GEN_TYPE) mobile = models.CharField('手机号', max_length=30, blank=True) head = PictureField('工牌照', max_length=200, blank=True) depart = models.ForeignKey(TBDepartment, null=True, blank=True, verbose_name='部门') user = models.OneToOneField(User, verbose_name='账号', null=True, blank=True) duty = models.CharField('职务', max_length=100, blank=True) nation = models.CharField('民族', max_length=30, blank=True) birthday = models.DateField('生日', null=True, blank=True) nickname = models.CharField('个性签名', max_length=200, blank=True) qq = models.CharField('QQ', max_length=50, blank=True) def __str__(self): return self.name
class Yewu(models.Model): """ """ title = models.CharField('主标题', max_length=200) sub_title = models.CharField('副标题', max_length=600) cover = PictureField('封面', max_length=200, blank=True) av_area = models.ManyToManyField('Area', verbose_name='可用区域') desp = models.TextField('详细介绍', blank=True) group = models.ForeignKey(YewuGroup, verbose_name='业务分组') def get_url(self): return '/yewu/%s' % self.pk def __str__(self): if getattr(self, 'group', None): return r'%(group)s/%(yewu)s' % { 'group': self.group, 'yewu': self.title } else: return r'%(yewu)s' % {'yewu': self.title}
class WorkInfo(models.Model): user = models.OneToOneField(User, verbose_name='账号') name = models.CharField('姓名', max_length=200, blank=True) contact = models.CharField('电话', max_length=200, blank=True) address = models.CharField('地址', max_length=400, blank=True) head = PictureField('头像', blank=True, max_length=300, help_text='2寸标准证件照') id_face1 = PictureField('身份证正面', blank=True, max_length=300) id_face2 = PictureField('身份证反面', blank=True, max_length=300) bank_cover = PictureField('银行卡正面', blank=True, max_length=300) bank_code = models.CharField('卡号', blank=True, max_length=300) opening_bank = models.CharField('开户行', blank=True, max_length=400) education = PictureField('学历证明', blank=True, max_length=300) vocational_certificate = PictureField('职业证书', blank=True, max_length=300) skills_certificate = PictureField('技能证书', blank=True, max_length=300) #service_agreement = PictureField('自由职业者服务协议',blank=True,max_length=300) update_time = models.DateTimeField(verbose_name='更新时间', auto_now=True) status = models.IntegerField(verbose_name='当前状态', choices=COM_INFO_STATUS, default=0) def __str__(self): return self.name
class Banners(models.Model): img = PictureField('图片', max_length=200, blank=False) link = models.CharField('链接', max_length=500) belong = models.IntegerField('显示页面', choices=NAME_PAGES, default=1) priority = models.IntegerField('优先级', default=0, help_text='越大,优先级越高')