|
|
|
@ -154,7 +154,7 @@ def get_drug_manage():
|
|
|
|
|
# 编辑数据
|
|
|
|
|
@drug_router.route("/update", methods=["GET", "POST"])
|
|
|
|
|
@token_auth.login_required
|
|
|
|
|
def drug_add_update():
|
|
|
|
|
def drug_update():
|
|
|
|
|
finds_list = [
|
|
|
|
|
"name", "english_name", "bar_code", "cas_number",
|
|
|
|
|
"purity", "shelf_life", "production_date", "expiration_date",
|
|
|
|
@ -177,6 +177,19 @@ def drug_add_update():
|
|
|
|
|
return jsonify(Utils.true_return(msg="条码不能重复"))
|
|
|
|
|
return jsonify(Utils.true_return(msg="试剂id不能为空"))
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
# 编辑数据
|
|
|
|
|
@drug_router.route("/del", methods=["GET", "POST"])
|
|
|
|
|
@token_auth.login_required
|
|
|
|
|
def drug_del():
|
|
|
|
|
drug_id = request.values.get("medicament_id")
|
|
|
|
|
try:
|
|
|
|
|
BllMedicament().delete(EntityMedicament.medicament_id==drug_id)
|
|
|
|
|
return jsonify(Utils.true_return())
|
|
|
|
|
except Exception:
|
|
|
|
|
return jsonify(Utils.except_return(msg="删除失败"))
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
# 流转记录
|
|
|
|
|
@drug_router.route("/get_durg_record", methods=["GET", "POST"])
|
|
|
|
|
@token_auth.login_required
|
|
|
|
|