Commit 4fd284dd authored by xianyang's avatar xianyang

Merge branch 'develop/xp' into development

# Conflicts:
#	app/api/statement/guild.py
#	models/guild.py
parents 42ba5af3 76ca98d3
......@@ -3,5 +3,5 @@
<component name="JavaScriptSettings">
<option name="languageLevel" value="ES6" />
</component>
<component name="ProjectRootManager" version="2" project-jdk-name="Python 3.8 (financial-system)" project-jdk-type="Python SDK" />
<component name="ProjectRootManager" version="2" project-jdk-name="Python 3.8 (financial_system)" project-jdk-type="Python SDK" />
</project>
\ No newline at end of file
......@@ -102,15 +102,15 @@ class GuildSet(object):
count = db.query(func.count(GuildSettlementLog.id)).filter().scalar()
return list, count
def update_guild_info(self, data):
"""公会结算修改"""
id = data.get("id")
guild_sql = f"SELECT count(*) FROM `guild_settlement_log` where id={id})"
guild_data = self.linkmysql.query_mysql(guild_sql)
if guild_data:
status = 1 if data.get("status") == 0 else 2
guild_sql = f"UPDATE guild_settlement_log set status={status} where id={id}"
self.linkmysql.excete_mysql(guild_sql)
# def update_guild_info(self, data):
# """公会结算修改"""
# id = data.get("id")
# guild_sql = f"SELECT count(*) FROM `guild_settlement_log` where id={id})"
# guild_data = self.linkmysql.query_mysql(guild_sql)
# if guild_data:
# status = 1 if data.get("status") == 0 else 2
# guild_sql = f"UPDATE guild_settlement_log set status={status} where id={id}"
# self.linkmysql.excete_mysql(guild_sql)
def paymentset_guild_data(page, size, start_time, end_time):
......@@ -395,7 +395,6 @@ def create_fix_table(db: Session, param, h_list):
"timestamp": get_now_timestamp()
}
clearing_res = search(data, method)
print(clearing_res)
if clearing_res['status']:
unique_res = []
if param.type == 0:
......
......@@ -62,7 +62,7 @@ def guild_withdrawal_list(request:Request,db: Session = Depends(get_db),page: Op
@router.get("/guild/settlement")
def guild_settlement_list(db: Session = Depends(get_db),page: Optional[int] = 1, size: Optional[int] = 10,status:Optional[int]='',start_time:Optional[str]='',end_time:Optional[str]="",guild_id:Optional[str]=""):
"""公会结算"""
"""申请结算列表"""
guild_list, total = GuildSet().get_guild_data(db,page, size,status,start_time,end_time,guild_id)
return HttpResultResponse(total=total, data=guild_list)
......
......@@ -140,11 +140,14 @@ class GuildSettlementLog(Base, SerializerMixin):
work_id =Column(Integer, comment="业务id")
guild_id = Column(Integer, comment="公会id")
balance = Column(DECIMAL(15,3),default='0.000',comment="结算时的钻石,RMB单位")
bank_name =Column(String(122), comment="开户行名称")
bank_no =Column(String(122), comment="账户名称")
guild_name =Column(String(122), comment="公会名字")
pearl = Column(DECIMAL(15,3),default='0.000', comment="结算时候的珍珠,RMB单位")
status = Column(Integer, comment="0待结算,1待结款,2已完成")
create_time = Column(Integer,default='0',comment="创建时间")
update_time = Column(Integer,default='0',comment="修改时间")
guild_name = Column(Integer, comment="公会名字")
update_time = Column(DateTime,default='0',comment="修改时间")
account_name = Column(String(122), comment="户头名称")
guild_per = Column(String(122), comment="公会比例")
actual_money = Column(DECIMAL(15,3), default='0.000', comment="实际结款")
pledge_deposit_money = Column(DECIMAL, default='0.000', comment="质押金金额")
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment