|
@@ -16,7 +16,7 @@ $(function () {
|
|
|
initGenderSelect();
|
|
|
iniAdmissStatus();
|
|
|
initListDeptSelect();
|
|
|
- initTryResultSelect();
|
|
|
+ //initTryResultSelect();
|
|
|
initResponceTypeSelect();
|
|
|
initTemplateTypeSelect();
|
|
|
initTemplateKindTypeSelect('templateKindType');
|
|
@@ -1935,11 +1935,10 @@ function fitxyContent(pyPrescription, contentId, titleId, checkBox) {
|
|
|
xypyHtml += " ";
|
|
|
xypyHtml += pyDetail.orderDays;
|
|
|
xypyHtml += "天 ";
|
|
|
- if (pyDetail.tryResult != undefined && pyDetail.tryResult != null && pyDetail.tryResult != "null" && pyDetail.tryResult != "") {
|
|
|
- xypyHtml += pyDetail.tryResult;
|
|
|
- }
|
|
|
if (pyDetail.tryFlag != undefined && pyDetail.tryFlag != null && pyDetail.tryFlag != "null" && pyDetail.tryFlag != "") {
|
|
|
xypyHtml += pyDetail.tryFlag;
|
|
|
+ }else if (pyDetail.tryResult != undefined && pyDetail.tryResult != null && pyDetail.tryResult != "null" && pyDetail.tryResult != "") {
|
|
|
+ xypyHtml += pyDetail.tryResult;
|
|
|
}
|
|
|
if (checkBox) {
|
|
|
xypyHtml += "</span>";
|
|
@@ -2521,12 +2520,9 @@ function editPrescription(jsonData, type) {
|
|
|
$("#orderFrequency").selectpicker('val', mzChargeDetail.frequency);
|
|
|
$('#orderFrequency').selectpicker('refresh');
|
|
|
if (mzChargeDetail.tryFlag == 1 || mzChargeDetail.tryFlag == "1") {
|
|
|
- var tryFlag = $("#tryFlag").parent().hasClass("checked");
|
|
|
- if (tryFlag == false || tryFlag == "false") {
|
|
|
- $("#tryFlag").parent().parent().click();
|
|
|
- }
|
|
|
- }
|
|
|
- if (mzChargeDetail.tryResult != null && mzChargeDetail.tryResult != "null" && mzChargeDetail.tryResult != "") {
|
|
|
+ $("#tryResult").selectpicker('val', 100);
|
|
|
+ $('#tryResult').selectpicker('refresh');
|
|
|
+ } else if (mzChargeDetail.tryResult != null && mzChargeDetail.tryResult != "null" && mzChargeDetail.tryResult != "") {
|
|
|
$("#tryResult").selectpicker('val', mzChargeDetail.tryResult);
|
|
|
$('#tryResult').selectpicker('refresh');
|
|
|
}
|
|
@@ -2849,11 +2845,19 @@ function initZyClassTypeSelect() {
|
|
|
|
|
|
/**
|
|
|
* 初始化皮试结果下拉选
|
|
|
+ * @param categoriesFlag 0 口服 2 注射针剂
|
|
|
*/
|
|
|
-function initTryResultSelect() {
|
|
|
- var tryResult = '<option value="0">阴性</option><option value="3">免试</option>';
|
|
|
+function initTryResultSelect(categoriesFlag) {
|
|
|
+ var tryResult = '';
|
|
|
+ if (categoriesFlag == 2 || categoriesFlag == "2") {
|
|
|
+ tryResult += '<option value="100">皮试</option>';
|
|
|
+ }
|
|
|
+ tryResult += '<option value="0">阴性</option><option value="3">免试</option>';
|
|
|
+ //var tryResult = '<option value="100">皮试</option><option value="0">阴性</option><option value="3">免试</option>';
|
|
|
$('#tryResult').html(tryResult);
|
|
|
$('#tryResult').selectpicker('refresh');
|
|
|
+ //口服药选择皮试结果
|
|
|
+ $("#tryResult").parent().parent().parent().removeClass("hide").addClass("in");
|
|
|
}
|
|
|
|
|
|
/**
|
|
@@ -3387,8 +3391,6 @@ function saveWesternMedicine(calculateTotalAmountFlag) {
|
|
|
var totalRetprice = parseFloat($("#totalRetprice").val());
|
|
|
//单价
|
|
|
var packRetprice = $("#packRetprice").val();
|
|
|
- //皮试
|
|
|
- var tryFlag = $("#tryFlag").parent().hasClass("checked");
|
|
|
//皮试结果
|
|
|
var tryResult = $("#tryResult").val();
|
|
|
if (currentCode == null || currentCode == '') {
|
|
@@ -3433,11 +3435,12 @@ function saveWesternMedicine(calculateTotalAmountFlag) {
|
|
|
html += drugWin + drugWinUnit + ' ';
|
|
|
html += '频次:' + orderFrequencyText + ' ';
|
|
|
html += dayNum + '天 ';
|
|
|
- if (tryFlag == "true" || tryFlag == true) {
|
|
|
- html += '皮试 ';
|
|
|
- }
|
|
|
if (tryResult != null && tryResult != 'null' && tryResult != "") {
|
|
|
- html += '皮试结果: ' + $('#tryResult option:selected').text();
|
|
|
+ if (tryResult == "100" || tryResult == 100) {
|
|
|
+ html += '皮试 ';
|
|
|
+ } else {
|
|
|
+ html += '皮试结果: ' + $('#tryResult option:selected').text();
|
|
|
+ }
|
|
|
}
|
|
|
if (medicalAdvice != null && medicalAdvice != '') {
|
|
|
html += '医嘱:' + medicalAdviceText;
|
|
@@ -3460,7 +3463,6 @@ function saveWesternMedicine(calculateTotalAmountFlag) {
|
|
|
html += '<input type="hidden" class="temporary_items_medicalAdvice" value="' + medicalAdvice + '"/>';
|
|
|
html += '<input type="hidden" class="temporary_items_medicalAdviceText" value="' + medicalAdviceText + '"/>';
|
|
|
html += '<input type="hidden" class="temporary_items_packRetprice" value="' + packRetprice + '"/>';
|
|
|
- html += '<input type="hidden" class="temporary_items_tryFlag" value="' + tryFlag + '"/>';
|
|
|
html += '<input type="hidden" class="temporary_items_tryResult" value="' + tryResult + '"/>';
|
|
|
html += '<input type="hidden" class="temporary_items_currentGroupNo" value="' + currentGroupNo + '"/>';
|
|
|
html += '</div>';
|
|
@@ -3627,15 +3629,8 @@ function editWesternMedicine(obj) {
|
|
|
$("#totalRetprice").val($(parentObject).find("input.temporary_items_amount").val());
|
|
|
//单价
|
|
|
$("#packRetprice").val($(parentObject).find("input.temporary_items_packRetprice").val());
|
|
|
- //皮试
|
|
|
- var tryFlag = $(parentObject).find("input.temporary_items_tryFlag").val();
|
|
|
- if (tryFlag == true || tryFlag == "true") {
|
|
|
- $("#tryFlag").parent().parent().click();
|
|
|
- }
|
|
|
//皮试结果
|
|
|
var tryResult = $(parentObject).find("input.temporary_items_tryResult").val();
|
|
|
- $("#tryResult").val(tryResult);
|
|
|
- $('#tryResult').selectpicker('refresh');
|
|
|
//设置当前药品类型
|
|
|
$("#current_groupNo").val($(parentObject).find("input.temporary_items_currentGroupNo").val());
|
|
|
$.ajax({
|
|
@@ -3687,10 +3682,10 @@ function editWesternMedicine(obj) {
|
|
|
$('#packUnit').selectpicker('refresh');
|
|
|
}
|
|
|
if (res.data.psFlag != null && (res.data.psFlag == 1 || res.data.psFlag == "1")) {
|
|
|
- if (res.data.categoriesFlag == 0 || res.data.categoriesFlag == "0") {
|
|
|
- $("#tryResult").parent().parent().parent().removeClass("hide").addClass("in");
|
|
|
- } else if (res.data.categoriesFlag == 2 || res.data.categoriesFlag == "2") {
|
|
|
- $("#tryFlag").parent().parent().parent().removeClass("hide").addClass("in");
|
|
|
+ if (res.data.categoriesFlag == 0 || res.data.categoriesFlag == "0" || res.data.categoriesFlag == 2 || res.data.categoriesFlag == "2") {
|
|
|
+ initTryResultSelect(res.data.categoriesFlag);
|
|
|
+ $("#tryResult").val(tryResult);
|
|
|
+ $('#tryResult').selectpicker('refresh');
|
|
|
}
|
|
|
}
|
|
|
//厂家名称
|
|
@@ -4323,12 +4318,6 @@ function clearWesternMedicine(flag) {
|
|
|
//医嘱
|
|
|
$("#medicalAdvice").selectpicker('val', null);
|
|
|
$('#medicalAdvice').selectpicker('refresh');
|
|
|
- //皮试
|
|
|
- var tryFlag = $("#tryFlag").parent().hasClass("checked");
|
|
|
- if (tryFlag == true || tryFlag == "true") {
|
|
|
- $("#tryFlag").parent().parent().click();
|
|
|
- }
|
|
|
- $("#tryFlag").parent().parent().parent().removeClass("in").addClass("hide");
|
|
|
$("#tryResult").parent().parent().parent().removeClass("in").addClass("hide");
|
|
|
//皮试结果
|
|
|
$("#tryResult").selectpicker('val', null);
|
|
@@ -6665,19 +6654,10 @@ function fitWesternMedicine(res, groupNo) {
|
|
|
$("#orderFrequency").selectpicker('val', "ONCE");
|
|
|
$('#orderFrequency').selectpicker('refresh');
|
|
|
}
|
|
|
- $("#tryFlag").parent().parent().parent().removeClass("in").addClass("hide");
|
|
|
$("#tryResult").parent().parent().parent().removeClass("in").addClass("hide");
|
|
|
if (res.data.psFlag != null && (res.data.psFlag == 1 || res.data.psFlag == "1")) {
|
|
|
- if (res.data.categoriesFlag == 0 || res.data.categoriesFlag == "0") {
|
|
|
- //口服药选择皮试结果
|
|
|
- $("#tryResult").parent().parent().parent().removeClass("hide").addClass("in");
|
|
|
- } else if (res.data.categoriesFlag == 2 || res.data.categoriesFlag == "2") {
|
|
|
- //针剂需要皮试
|
|
|
- $("#tryFlag").parent().parent().parent().removeClass("hide").addClass("in");
|
|
|
- var tryFlag = $("#tryFlag").parent().hasClass("checked");
|
|
|
- if (tryFlag == false || tryFlag == "false") {
|
|
|
- $("#tryFlag").parent().parent().click();
|
|
|
- }
|
|
|
+ if (res.data.categoriesFlag == 0 || res.data.categoriesFlag == "0" || res.data.categoriesFlag == 2 || res.data.categoriesFlag == "2") {
|
|
|
+ initTryResultSelect(res.data.categoriesFlag);
|
|
|
}
|
|
|
}
|
|
|
$("#manufactoryName").val(res.data.manufactoryName);
|
|
@@ -7307,11 +7287,14 @@ function getParamsForpPrescription(type) {
|
|
|
tempJson.orderNo = orderNo;
|
|
|
tempJson.groupOrder = $(formGroups[j]).find("input.temporary_items_groupId").val();
|
|
|
tempJson.groupNo = currentGroupNo;
|
|
|
- var tryFlag = $(formGroups[j]).find("input.temporary_items_tryFlag").val();
|
|
|
- if (tryFlag == true || tryFlag == "true") {
|
|
|
- tempJson.tryFlag = 1;
|
|
|
+ var tryResult = $(formGroups[j]).find("input.temporary_items_tryResult").val();
|
|
|
+ if (tryResult != undefined || tryResult != null || tryResult != "") {
|
|
|
+ if (tryResult == 100 || tryResult == "100") {
|
|
|
+ tempJson.tryFlag = 1;
|
|
|
+ } else {
|
|
|
+ tempJson.tryResult = tryResult;
|
|
|
+ }
|
|
|
}
|
|
|
- tempJson.tryResult = $(formGroups[j]).find("input.temporary_items_tryResult").val();
|
|
|
jsonData.mzChargeDetailList[jsonData.mzChargeDetailList.length] = tempJson;
|
|
|
}
|
|
|
}
|