Files
jyls_django/finance/models.py
2026-01-20 15:52:22 +08:00

86 lines
5.0 KiB
Python
Raw Permalink Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

from django.db import models
# Create your models here.
class Invoice(models.Model):
ContractNo = models.TextField() # 合同号
personincharge = models.CharField(max_length=100) # 负责人
amount =models.CharField(max_length=100) # 开票金额
type = models.CharField(max_length=100) # 开票类型
unit = models.CharField(max_length=100) # 开票单位全称
number = models.CharField(max_length=100) # 纳税人识别号
address_telephone = models.CharField(max_length=100) # 地址/电话
bank = models.CharField(max_length=100) # 银行卡
state = models.CharField(max_length=100) # 状态
username = models.CharField(max_length=100) # 谁提交的
times = models.TextField() # 提交时间
approvers_order = models.TextField(null=True, blank=True) # 审核人顺序JSON格式存储["张三","李四","王五"]
is_deleted = models.BooleanField(default=False) # 软删除标记
class Income(models.Model):
times = models.CharField(max_length=100) # 收款日期
ContractNo = models.CharField(max_length=100) # 合同号
CustomerID = models.CharField(max_length=100) # 客户名称
amount = models.CharField(max_length=100) # 收款金额
allocate = models.CharField(max_length=100) # 收入分配
submit = models.CharField(max_length=100) # 谁提交的
submit_tiem = models.CharField(max_length=100) # 提交时间
state = models.CharField(max_length=100) # 状态
approvers_order = models.TextField(null=True, blank=True) # 审核人顺序JSON格式存储["张三","李四","王五"]
is_deleted = models.BooleanField(default=False) # 软删除标记
class Accounts(models.Model):
times = models.CharField(max_length=100) # 收款日期
ContractNo = models.CharField(max_length=100) # 合同号
CustomerID = models.CharField(max_length=100) # 客户名称
amount = models.CharField(max_length=100) # 收款金额
situation = models.TextField() # 情况
submit = models.CharField(max_length=100) # 谁提交的
submit_tiem = models.CharField(max_length=100) # 提交时间
state = models.CharField(max_length=100) # 状态
is_deleted = models.BooleanField(default=False) # 软删除标记
class Payment(models.Model):
# 新字段(允许为空,用于兼容旧数据)
payment_reason = models.TextField(null=True, blank=True) # 付款事由
payee_name = models.CharField(max_length=100, null=True, blank=True) # 收款方名称
payee_account = models.CharField(max_length=100, null=True, blank=True) # 收款方银行账号
payee_bank = models.CharField(max_length=100, null=True, blank=True) # 收款方开户行
payment_description = models.TextField(null=True, blank=True) # 支付说明
payment_type = models.CharField(max_length=50, default='律所支付', null=True, blank=True) # 支付方式:律所支付/自己账户支付
# 原有字段
reason = models.TextField(null=True, blank=True) # 付款理由(兼容旧字段)
amount = models.CharField(max_length=100) # 付款金额
times = models.CharField(max_length=100, null=True, blank=True) # 付款日期(可选)
payee = models.CharField(max_length=100, null=True, blank=True) # 收款人(兼容旧字段)
bankcard = models.CharField(max_length=100, null=True, blank=True) # 银行卡(兼容旧字段)
BankName = models.CharField(max_length=100, null=True, blank=True) # 开户行(兼容旧字段)
applicant = models.CharField(max_length=100) # 申请人
submit_tiem = models.CharField(max_length=100) # 提交时间
state = models.CharField(max_length=100) # 状态
approvers_order = models.TextField(null=True, blank=True) # 审核人顺序JSON格式存储["张三","李四","王五"]
is_deleted = models.BooleanField(default=False) # 软删除标记
class Reimbursement(models.Model):
person = models.CharField(max_length=100) # 报销人
times = models.CharField(max_length=100) # 报销日期
reason = models.TextField() # 报销理由
amount = models.CharField(max_length=100) # 报销金额
FeeDescription = models.TextField() # 费用说明
submit_tiem = models.CharField(max_length=100) # 提交时间
state = models.CharField(max_length=100) # 状态
approvers_order = models.TextField(null=True, blank=True) # 审核人顺序JSON格式存储["张三","李四","王五"]
is_deleted = models.BooleanField(default=False) # 软删除标记
class BonusChange(models.Model):
username = models.CharField(max_length=100)
type = models.CharField(max_length=100)
Instructions = models.TextField() # 调整说明
times = models.CharField(max_length=100) # 时间
state = models.CharField(max_length=100) # 状态
submitter = models.CharField(max_length=100, null=True, blank=True) # 提交人
approvers_order = models.TextField(null=True, blank=True) # 审核人顺序JSON格式存储["张三","李四","王五"]
is_deleted = models.BooleanField(default=False) # 软删除标记