完善采购审批流程、企业微信通知和采购专用章

This commit is contained in:
reddaniel110
2026-09-16 11:45:21 +08:00
parent 4876d8805d
commit bf952196fa
58 changed files with 3451 additions and 1909 deletions
+3 -26
View File
@@ -1,28 +1,5 @@
# -*- coding: utf-8 -*-
"""快速检查统计页与台账导出。"""
import http.cookiejar
import urllib.parse
import urllib.request
BASE = "http://127.0.0.1:8080"
def main():
cj = http.cookiejar.CookieJar()
op = urllib.request.build_opener(urllib.request.HTTPCookieProcessor(cj))
op.open(urllib.request.Request(
BASE + "/login",
data=urllib.parse.urlencode({"username": "admin", "password": "admin123"}).encode()),
timeout=30)
for path, expect in [("/stats", b"200"), ("/export/ledger", b"xlsx"),
("/orders", b"200"), ("/suppliers", b"200"),
("/materials", b"200"), ("/users", b"200"), ("/", b"200")]:
r = op.open(BASE + path, timeout=30)
data = r.read()
print(path, r.status, len(data))
assert r.status == 200, path
print("PAGES OK")
"""Compatibility entry point; tests only use temporary databases."""
from run_tests import main
if __name__ == "__main__":
main()
raise SystemExit(main(('-k', 'pages')))