diff --git a/models/sub_distributors.json b/models/sub_distributors.json index 91a061a..02972c8 100644 --- a/models/sub_distributors.json +++ b/models/sub_distributors.json @@ -1,143 +1,159 @@ { - "summary": [ - { - "name": "sub_distributors", - "title": "二级分销商表", - "primary": ["id"], - "catelog": "entity" - } - ], - "fields": [ - { - "name": "id", - "title": "主键ID", - "type": "str", - "length": 32, - "nullable": "no" - }, - { - "name": "resellerid", - "title": "所属主分销商机构ID", - "type": "str", - "length": 32, - "nullable": "no" - }, - { - "name": "sub_dist_code", - "title": "二级分销商编号", - "type": "str", - "length": 64, - "nullable": "no" - }, - { - "name": "sub_dist_name", - "title": "二级分销商名称", - "type": "str", - "length": 255, - "nullable": "no" - }, - { - "name": "contact_person", - "title": "联系人", - "type": "str", - "length": 100 - }, - { - "name": "contact_phone", - "title": "联系电话", - "type": "str", - "length": 50 - }, - { - "name": "contact_email", - "title": "联系邮箱", - "type": "str", - "length": 255 - }, - { - "name": "address", - "title": "地址", - "type": "str", - "length": 500 - }, - { - "name": "tax_number", - "title": "税号", - "type": "str", - "length": 64 - }, - { - "name": "bank_name", - "title": "开户银行", - "type": "str", - "length": 255 - }, - { - "name": "bank_account", - "title": "银行账号", - "type": "str", - "length": 64 - }, - { - "name": "managed_by", - "title": "负责销售ID", - "type": "str", - "length": 32 - }, - { - "name": "status", - "title": "状态", - "type": "char", - "length": 1, - "nullable": "no", - "default": "1" - }, - { - "name": "remark", - "title": "备注", - "type": "text" - }, - { - "name": "created_by", - "title": "创建人", - "type": "str", - "length": 32 - }, - { - "name": "created_at", - "title": "创建时间", - "type": "datetime", - "nullable": "no" - }, - { - "name": "updated_at", - "title": "更新时间", - "type": "datetime" - } - ], - "indexes": [ - { - "name": "idx_sd_reseller", - "idxtype": "index", - "idxfields": ["resellerid"] - }, - { - "name": "idx_sd_code", - "idxtype": "unique", - "idxfields": ["resellerid", "sub_dist_code"] - }, - { - "name": "idx_sd_manager", - "idxtype": "index", - "idxfields": ["managed_by"] - } - ], - "codes": [ - { - "field": "resellerid", - "table": "organization", - "valuefield": "id", - "textfield": "orgname" - } - ] -} + "summary": [ + { + "name": "sub_distributors", + "title": "二级分销商表", + "primary": [ + "id" + ], + "catelog": "entity" + } + ], + "fields": [ + { + "name": "id", + "title": "主键ID", + "type": "str", + "length": 32, + "nullable": "no" + }, + { + "name": "resellerid", + "title": "所属主分销商机构ID", + "type": "str", + "length": 32, + "nullable": "no" + }, + { + "name": "sub_dist_code", + "title": "二级分销商编号", + "type": "str", + "length": 64, + "nullable": "no" + }, + { + "name": "sub_dist_name", + "title": "二级分销商名称", + "type": "str", + "length": 255, + "nullable": "no" + }, + { + "name": "contact_person", + "title": "联系人", + "type": "str", + "length": 100 + }, + { + "name": "contact_phone", + "title": "联系电话", + "type": "str", + "length": 50 + }, + { + "name": "contact_email", + "title": "联系邮箱", + "type": "str", + "length": 255 + }, + { + "name": "address", + "title": "地址", + "type": "str", + "length": 500 + }, + { + "name": "tax_number", + "title": "税号", + "type": "str", + "length": 64 + }, + { + "name": "bank_name", + "title": "开户银行", + "type": "str", + "length": 255 + }, + { + "name": "bank_account", + "title": "银行账号", + "type": "str", + "length": 64 + }, + { + "name": "managed_by", + "title": "负责销售ID", + "type": "str", + "length": 32 + }, + { + "name": "status", + "title": "状态", + "type": "char", + "length": 1, + "nullable": "no", + "default": "1" + }, + { + "name": "remark", + "title": "备注", + "type": "text" + }, + { + "name": "created_by", + "title": "创建人", + "type": "str", + "length": 32 + }, + { + "name": "created_at", + "title": "创建时间", + "type": "datetime", + "nullable": "no" + }, + { + "name": "updated_at", + "title": "更新时间", + "type": "datetime" + } + ], + "indexes": [ + { + "name": "idx_sd_reseller", + "idxtype": "index", + "idxfields": [ + "resellerid" + ] + }, + { + "name": "idx_sd_code", + "idxtype": "unique", + "idxfields": [ + "resellerid", + "sub_dist_code" + ] + }, + { + "name": "idx_sd_manager", + "idxtype": "index", + "idxfields": [ + "managed_by" + ] + } + ], + "codes": [ + { + "field": "resellerid", + "table": "organization", + "valuefield": "id", + "textfield": "orgname" + }, + { + "field": "status", + "table": "appcodes_kv", + "valuefield": "k", + "textfield": "v", + "cond": "parentid='sub_distributor_status'" + } + ] +} \ No newline at end of file diff --git a/models/suppliers.json b/models/suppliers.json index aeb083b..f1da846 100644 --- a/models/suppliers.json +++ b/models/suppliers.json @@ -1,203 +1,219 @@ { - "summary": [ - { - "name": "suppliers", - "title": "供应商表", - "primary": ["id"], - "catelog": "entity" - } - ], - "fields": [ - { - "name": "id", - "title": "主键ID", - "type": "str", - "length": 32, - "nullable": "no" - }, - { - "name": "resellerid", - "title": "所属分销商机构ID", - "type": "str", - "length": 32, - "nullable": "no" - }, - { - "name": "supplier_code", - "title": "供应商编号", - "type": "str", - "length": 64, - "nullable": "no" - }, - { - "name": "supplier_name", - "title": "供应商名称", - "type": "str", - "length": 255, - "nullable": "no" - }, - { - "name": "contact_person", - "title": "联系人", - "type": "str", - "length": 100 - }, - { - "name": "contact_phone", - "title": "联系电话", - "type": "str", - "length": 50 - }, - { - "name": "contact_email", - "title": "联系邮箱", - "type": "str", - "length": 255 - }, - { - "name": "address", - "title": "地址", - "type": "str", - "length": 500 - }, - { - "name": "tax_number", - "title": "税号", - "type": "str", - "length": 64 - }, - { - "name": "bank_name", - "title": "开户银行", - "type": "str", - "length": 255 - }, - { - "name": "bank_account", - "title": "银行账号", - "type": "str", - "length": 64 - }, - { - "name": "orgid", - "title": "机构ID", - "type": "str", - "length": 32, - "nullable": "no" - }, - { - "name": "is_external", - "title": "是否外部供应商", - "type": "char", - "length": 1, - "nullable": "no", - "default": "1" - }, - { - "name": "settlement_cycle", - "title": "结算周期", - "type": "str", - "length": 20 - }, - { - "name": "settlement_day", - "title": "结算日", - "type": "int" - }, - { - "name": "payment_type", - "title": "付款方式", - "type": "str", - "length": 20 - }, - { - "name": "status", - "title": "状态", - "type": "char", - "length": 1, - "nullable": "no", - "default": "1" - }, - { - "name": "remark", - "title": "备注", - "type": "text" - }, - { - "name": "created_by", - "title": "创建人", - "type": "str", - "length": 32 - }, - { - "name": "created_at", - "title": "创建时间", - "type": "datetime", - "nullable": "no" - }, - { - "name": "updated_at", - "title": "更新时间", - "type": "datetime" - } - ], - "indexes": [ - { - "name": "idx_suppliers_reseller", - "idxtype": "index", - "idxfields": ["resellerid"] - }, - { - "name": "idx_suppliers_orgid", - "idxtype": "index", - "idxfields": ["orgid"] - }, - { - "name": "idx_suppliers_code", - "idxtype": "unique", - "idxfields": ["resellerid", "supplier_code"] - } - ], - "codes": [ - { - "field": "resellerid", - "table": "organization", - "valuefield": "id", - "textfield": "orgname" - }, - { - "field": "orgid", - "table": "organization", - "valuefield": "id", - "textfield": "orgname" - }, - { - "field": "is_external", - "table": "appcodes_kv", - "valuefield": "k", - "textfield": "v", - "cond": "parentid='supplier_is_external'" - }, - { - "field": "payment_type", - "table": "appcodes_kv", - "valuefield": "k", - "textfield": "v", - "cond": "parentid='supplier_payment_type'" - }, - { - "field": "settlement_cycle", - "table": "appcodes_kv", - "valuefield": "k", - "textfield": "v", - "cond": "parentid='supplier_settle_cycle'" - }, - { - "field": "status", - "table": "appcodes_kv", - "valuefield": "k", - "textfield": "v", - "cond": "parentid='supplier_status'" - } - ] -} + "summary": [ + { + "name": "suppliers", + "title": "供应商表", + "primary": [ + "id" + ], + "catelog": "entity" + } + ], + "fields": [ + { + "name": "id", + "title": "主键ID", + "type": "str", + "length": 32, + "nullable": "no" + }, + { + "name": "resellerid", + "title": "所属分销商机构ID", + "type": "str", + "length": 32, + "nullable": "no" + }, + { + "name": "supplier_code", + "title": "供应商编号", + "type": "str", + "length": 64, + "nullable": "no" + }, + { + "name": "supplier_name", + "title": "供应商名称", + "type": "str", + "length": 255, + "nullable": "no" + }, + { + "name": "contact_person", + "title": "联系人", + "type": "str", + "length": 100 + }, + { + "name": "contact_phone", + "title": "联系电话", + "type": "str", + "length": 50 + }, + { + "name": "contact_email", + "title": "联系邮箱", + "type": "str", + "length": 255 + }, + { + "name": "address", + "title": "地址", + "type": "str", + "length": 500 + }, + { + "name": "tax_number", + "title": "税号", + "type": "str", + "length": 64 + }, + { + "name": "bank_name", + "title": "开户银行", + "type": "str", + "length": 255 + }, + { + "name": "bank_account", + "title": "银行账号", + "type": "str", + "length": 64 + }, + { + "name": "orgid", + "title": "机构ID", + "type": "str", + "length": 32, + "nullable": "no" + }, + { + "name": "is_external", + "title": "是否外部供应商", + "type": "char", + "length": 1, + "nullable": "no", + "default": "1" + }, + { + "name": "settlement_cycle", + "title": "结算周期", + "type": "str", + "length": 20 + }, + { + "name": "settlement_day", + "title": "结算日", + "type": "int" + }, + { + "name": "payment_type", + "title": "付款方式", + "type": "str", + "length": 20 + }, + { + "name": "status", + "title": "状态", + "type": "char", + "length": 1, + "nullable": "no", + "default": "1" + }, + { + "name": "remark", + "title": "备注", + "type": "text" + }, + { + "name": "created_by", + "title": "创建人", + "type": "str", + "length": 32 + }, + { + "name": "created_at", + "title": "创建时间", + "type": "datetime", + "nullable": "no" + }, + { + "name": "updated_at", + "title": "更新时间", + "type": "datetime" + } + ], + "indexes": [ + { + "name": "idx_suppliers_reseller", + "idxtype": "index", + "idxfields": [ + "resellerid" + ] + }, + { + "name": "idx_suppliers_orgid", + "idxtype": "index", + "idxfields": [ + "orgid" + ] + }, + { + "name": "idx_suppliers_code", + "idxtype": "unique", + "idxfields": [ + "resellerid", + "supplier_code" + ] + } + ], + "codes": [ + { + "field": "resellerid", + "table": "organization", + "valuefield": "id", + "textfield": "orgname" + }, + { + "field": "orgid", + "table": "organization", + "valuefield": "id", + "textfield": "orgname" + }, + { + "field": "is_external", + "table": "appcodes_kv", + "valuefield": "k", + "textfield": "v", + "cond": "parentid='supplier_is_external'" + }, + { + "field": "payment_type", + "table": "appcodes_kv", + "valuefield": "k", + "textfield": "v", + "cond": "parentid='supplier_payment_type'" + }, + { + "field": "settlement_cycle", + "table": "appcodes_kv", + "valuefield": "k", + "textfield": "v", + "cond": "parentid='supplier_settle_cycle'" + }, + { + "field": "status", + "table": "appcodes_kv", + "valuefield": "k", + "textfield": "v", + "cond": "parentid='supplier_status'" + }, + { + "field": "status", + "table": "appcodes_kv", + "valuefield": "k", + "textfield": "v", + "cond": "parentid='supplier_status'" + } + ] +} \ No newline at end of file diff --git a/supplychain/__pycache__/init.cpython-310.pyc b/supplychain/__pycache__/init.cpython-310.pyc index c09cad6..35e0935 100644 Binary files a/supplychain/__pycache__/init.cpython-310.pyc and b/supplychain/__pycache__/init.cpython-310.pyc differ