员工岗位可重新启用;调价认空运航线;会话存档跳号补拉;陆运报价按车型列回填
Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
@@ -31,24 +31,25 @@ class LandFieldValidateTest(unittest.TestCase):
|
||||
self.assertFalse(got["ok"])
|
||||
self.assertIn("体积", got["missing"])
|
||||
|
||||
def test_hk_lcl_still_needs_vehicle(self):
|
||||
def test_hk_lcl_skips_vehicle(self):
|
||||
"""中港零担/集拼:询价不要车型/数量。"""
|
||||
got = validate_required_fields(
|
||||
facts={
|
||||
"起运港": "广州",
|
||||
"目的港": "香港",
|
||||
"品名": "衣服",
|
||||
"体积": "10CBM",
|
||||
"毛重": "50kg",
|
||||
},
|
||||
business_line="LAND",
|
||||
land_subtype="中港零担/集拼",
|
||||
)
|
||||
self.assertIn("车型/数量", got["missing"])
|
||||
self.assertNotIn("数量", got["missing"])
|
||||
self.assertNotIn("车型", got["missing"])
|
||||
self.assertTrue(got["ok"])
|
||||
self.assertNotIn("车型/数量", got["missing"])
|
||||
self.assertNotIn("体积", got["missing"])
|
||||
self.assertNotIn("毛重", got["missing"])
|
||||
|
||||
def test_hk_full_truck_skips_vehicle(self):
|
||||
got = validate_required_fields(
|
||||
def test_hk_full_truck_requires_vehicle(self):
|
||||
"""中港整车:询价必填车型/数量。"""
|
||||
missing = validate_required_fields(
|
||||
facts={
|
||||
"起运港": "广州",
|
||||
"目的港": "香港",
|
||||
@@ -57,8 +58,20 @@ class LandFieldValidateTest(unittest.TestCase):
|
||||
business_line="LAND",
|
||||
land_subtype="中港整车",
|
||||
)
|
||||
self.assertFalse(missing["ok"])
|
||||
self.assertIn("车型/数量", missing["missing"])
|
||||
got = validate_required_fields(
|
||||
facts={
|
||||
"起运港": "广州",
|
||||
"目的港": "香港",
|
||||
"品名": "衣服",
|
||||
"车型/数量": "9米6/1",
|
||||
},
|
||||
business_line="LAND",
|
||||
land_subtype="中港整车",
|
||||
)
|
||||
self.assertTrue(got["ok"])
|
||||
self.assertNotIn("车型/数量", got["missing"])
|
||||
self.assertEqual(got["facts"]["车型/数量"], "9米6/1")
|
||||
|
||||
def test_domestic_ftl_one_field(self):
|
||||
got = validate_required_fields(
|
||||
|
||||
Reference in New Issue
Block a user