Browse Source

中药出入库修改

WANGJIALIANG 2 năm trước cách đây
mục cha
commit
88a5271191

+ 1 - 0
src/main/java/cn/hnthyy/thmz/controller/yk/YpInDetlController.java

@@ -105,6 +105,7 @@ public class YpInDetlController {
                         YpOutDetlVo ypOutDetlVo = ypOutDetlVos.get(j);
                         if(ypInDetlVo.getChargeCode().equals(ypOutDetlVo.getChargeCode())
                                 && ypInDetlVo.getSerial().equals(ypOutDetlVo.getSerial())
+                                && ypInDetlVo.getInSeri().equals(ypOutDetlVo.getInSeri())
                                 && ypInDetlVo.getManuNo().equals(ypOutDetlVo.getManuNo())){
                             ypInDetlVo.setAmountOut(ypOutDetlVo.getOutAmt());
                         }

+ 2 - 2
src/main/java/cn/hnthyy/thmz/mapper/his/yp/YpInDetlMapper.java

@@ -355,10 +355,10 @@ public interface YpInDetlMapper {
             " values" +
             " <foreach item='item' collection='ypInDetlList' separator=','> " +
             "  (#{item.inDate,jdbcType=TIMESTAMP},#{item.inSeri,jdbcType=BIGINT},#{item.chargeCode,jdbcType=VARCHAR},#{item.serial,jdbcType=VARCHAR},#{item.buyAmt,jdbcType=DOUBLE}," +
-            " cast(#{item.buyPrice} as decimal(15,2)),#{item.effDate,jdbcType=DATE},#{item.manuNo,jdbcType=VARCHAR},#{item.reptNo,jdbcType=VARCHAR}," +
+            " cast(#{item.buyPrice} as decimal(15,3)),#{item.effDate,jdbcType=DATE},#{item.manuNo,jdbcType=VARCHAR},#{item.reptNo,jdbcType=VARCHAR}," +
             " #{item.inDocuNo,jdbcType=VARCHAR},#{item.supplyCode,jdbcType=VARCHAR},#{item.manuCode,jdbcType=VARCHAR},#{item.licenseNo,jdbcType=VARCHAR}," +
             " #{item.purchaser,jdbcType=VARCHAR},#{item.checker,jdbcType=VARCHAR},#{item.inComment,jdbcType=VARCHAR},#{item.inType,jdbcType=VARCHAR}," +
-            " cast(#{item.packRetprice} as decimal(15,2)),#{item.acctType,jdbcType=VARCHAR},cast(#{item.fixPrice} as decimal(15,2)),#{item.groupNo,jdbcType=VARCHAR}," +
+            " cast(#{item.packRetprice} as decimal(15,3)),#{item.acctType,jdbcType=VARCHAR},cast(#{item.fixPrice} as decimal(15,3)),#{item.groupNo,jdbcType=VARCHAR}," +
             " #{item.currentStock,jdbcType=DOUBLE},#{item.sysDate,jdbcType=TIMESTAMP},#{item.reptDate,jdbcType=DATE},#{item.inputId,jdbcType=VARCHAR}," +
             " #{item.stockAmount,jdbcType=DOUBLE},#{item.avgPrice,jdbcType=DOUBLE},#{item.producingDate,jdbcType=DATE})" +
             " </foreach>" +

+ 1 - 2
src/main/resources/static/js/yk/drug_delivery.js

@@ -458,7 +458,6 @@ function initInDetlDetailed() {
             root: "data", repeatitems: false
         },
         beforeSubmitCell: function (rowid, cellname, cellvalue, iRow, iCol) {
-            //let rowObject = $("#tb_table_indetl_detailed").getRowData(rowid);
             let rowId = $("#tb_table_detailed").jqGrid("getGridParam", "selrow");
             var rowData = $("#tb_table_detailed").jqGrid('getRowData', rowId);
             var data = $("#tb_table_indetl_detailed").jqGrid("getRowData");
@@ -467,7 +466,7 @@ function initInDetlDetailed() {
                 let rowObject = data[j];
                 for (let i = 0; i < outDetlList.length; i++) {
                     let data = outDetlList[i];
-                    if (data.inDocuNo === rowObject.inDocuNo && data.chargeCode === rowObject.chargeCode && data.manuNo === rowObject.manuNo) {
+                    if (data.inSeri === rowObject.inSeri && data.inDocuNo === rowObject.inDocuNo && data.chargeCode === rowObject.chargeCode && data.manuNo === rowObject.manuNo) {
                         outDetlList.splice(i, 1);
                         break;
                     }

+ 3 - 2
src/main/resources/static/js/yk/drug_storage.js

@@ -1,5 +1,5 @@
 //@ sourceURL=drug_storage.js
-var groupNo = window.localStorage["groupYk"];//药编码
+var groupNo = window.localStorage["groupYk"];//药编码
 $(function () {
     init_daterangepicker();
     $('.datetime').datetimepicker({
@@ -358,6 +358,7 @@ function recordTableQueryParams(params) {
         inType:'0,2,3',
         beginTime: rePortRangeArr[0],
         endTime: rePortRangeArr[1],
+        groupNo: groupNo,
         reptNo: $("#reptNoSearch").val() == '' ? null : $("#reptNoSearch").val(),
         supplyCode: $("#supplyCodeSearch").val() == '' ? null : $("#supplyCodeSearch").val(),
         confirmFlag: $("#confirmFlagSearch").val(),
@@ -774,7 +775,7 @@ function setPrintHtml() {
             html += '<td class="xtd" style="text-align: center;">' + buyPrice + '</td>';
             html += '<td class="xtd" style="text-align: center;">' + packRetprice + '</td>';
             html += '<td class="xtd" style="text-align: center;">' + data['manuNo'] + '</td>';
-            html += '<td class="xtd" style="text-align: left;">' + data['manufactoryName'] + '</td>';
+            html += '<td class="xtd" style="text-align: left;">' + (isEmpty(data['manufactoryName'])?'':data['manufactoryName']) + '</td>';
             html += '<td class="xtd" style="text-align: center;">' + format(data['effDate'], "yyyy-MM-dd") + '</td>';
             html += '</tr>';
         }