Index: ssts-diposablegoods/src/main/java/com/forgon/disinfectsystem/diposablegoods/service/DiposableGoodsManagerImpl.java
===================================================================
diff -u -r14454 -r14526
--- ssts-diposablegoods/src/main/java/com/forgon/disinfectsystem/diposablegoods/service/DiposableGoodsManagerImpl.java (.../DiposableGoodsManagerImpl.java) (revision 14454)
+++ ssts-diposablegoods/src/main/java/com/forgon/disinfectsystem/diposablegoods/service/DiposableGoodsManagerImpl.java (.../DiposableGoodsManagerImpl.java) (revision 14526)
@@ -275,13 +275,13 @@
}
setUpdatingProperties(curDisposableGoods, disposableGoods);
saveOrUpdate(curDisposableGoods);
- if(!StringUtils.equals(originalGoodsType, goodsType)){
- if(DisposableGoods.TYPE_DIPOSABLEGOODS.equals(originalGoodsType)){
- changeGoodsToExpensiveDiposablegoods_internal(curDisposableGoods);
- }else if(DisposableGoods.TYPE_EXPENSIVEDIPOSABLEGOODS.equals(originalGoodsType)){
- changeExpensiveDiposablegoodsToGoods_internal(curDisposableGoods);
- }
- }
+// if(!StringUtils.equals(originalGoodsType, goodsType)){
+// if(DisposableGoods.TYPE_DIPOSABLEGOODS.equals(originalGoodsType)){
+// changeGoodsToExpensiveDiposablegoods_internal(curDisposableGoods);
+// }else if(DisposableGoods.TYPE_EXPENSIVEDIPOSABLEGOODS.equals(originalGoodsType)){
+// changeExpensiveDiposablegoodsToGoods_internal(curDisposableGoods);
+// }
+// }
if(!StringUtils.isBlank(oldName) || !StringUtils.isBlank(newName)){
nameChanged = !StringUtils.equals(oldName, newName);
}
Index: ssts-web/src/main/webapp/disinfectsystem/assestManagement/disposableGoods/interfere/diposableGoodsView.js
===================================================================
diff -u
--- ssts-web/src/main/webapp/disinfectsystem/assestManagement/disposableGoods/interfere/diposableGoodsView.js (revision 0)
+++ ssts-web/src/main/webapp/disinfectsystem/assestManagement/disposableGoods/interfere/diposableGoodsView.js (revision 14526)
@@ -0,0 +1,1104 @@
+var entityName = "一次性物品";
+var grid;
+var root;
+var formObj;
+var formWindow;
+var autoFillExternalCodeOfDisposableGoods = false;
+function addDiposableGoods(id) {
+ autoFillExternalCodeOfDisposableGoods = getBoolValueFromJs('sstsConfig.autoFillExternalCodeOfDisposableGoods',autoFillExternalCodeOfDisposableGoods);
+ var dType = document.getElementById("parm_s_type").value;
+ var diposableGooodsStore = new Ext.data.SimpleStore({
+ fields : [ 'typeName' ],
+ url : WWWROOT + '/disinfectSystem/diposableGoodsAction!getDiposableGoodsType.do'
+ });
+
+ //能否作为器械包材料
+ var isPartOfTousseMaterialStore = new Ext.data.SimpleStore( {
+ fields : [ 'value'],
+ data : [[CONSTANT_YES],[CONSTANT_NO]]
+ });
+ var goodsTypeStore = new Ext.data.SimpleStore( {
+ fields : [ 'value'],
+ data : [['普通物品'],['高值耗材']]
+ });
+
+ //能否被科室申请
+ var isApplicationMaterialStore = new Ext.data.SimpleStore( {
+ fields : [ 'value'],
+ data : [[CONSTANT_YES],[CONSTANT_NO]]
+ });
+
+ //是否供应室物品
+ var yesNoStore = new Ext.data.SimpleStore( {
+ fields : [ 'value'],
+ data : [[STR_YES],[STR_NO]]
+ });
+
+ var godownEntryItemStore = new top.Ext.data.Store({
+ proxy : new top.Ext.data.HttpProxy({
+ url : WWWROOT + '/disinfectSystem/diposableGoodsAction!loadDisposableGoodsBatchesByDisposableGoodsID.do?id=' + id,
+ method : 'POST'
+ }),
+ reader : new top.Ext.data.JsonReader({
+ fields : [
+ {name : 'id'},
+ {name : 'barcode'},
+ {name : 'storage'},
+ {name : 'batchNumber'},
+ {name : 'cost'},
+ {name : 'expDate'},
+ {name : 'supplierName'}
+ ]
+ })
+ });
+
+
+ var selectModel = new top.Ext.grid.CheckboxSelectionModel();
+ formObj = new top.Ext.FormPanel( {
+ id : 'diposableGoodsForm',
+ frame : true,
+ labelAlign:'right',
+ labelSeparator : ':',
+ bodyStyle : 'padding:5px 5px 0px 5px',
+ autoHeight : true,
+ autoScroll : true,
+ items:[{
+ layout : 'column',
+ items : [{
+ columnWidth : 0.4,
+ layout : 'form',
+ labelWidth : 70,
+ items : [{
+ xtype : 'hidden',
+ name : 'id',
+ id : 'id'
+ },{
+ xtype : 'hidden',
+ name : 'originalFormParams',
+ id : 'originalFormParams'
+ },{
+ xtype : 'hidden',
+ name : 'originalGoodsType',
+ id : 'originalGoodsType'
+ },{
+ xtype : 'hidden',
+ name : 'orginalName',
+ id : 'orginalName'
+ },{
+ xtype : 'hidden',
+ name : 'orginalSpecification',
+ id : 'orginalSpecification'
+ },{
+ xtype : 'hidden',
+ name : 'items',
+ id : 'items'
+ },{
+ columnWidth : 1,
+ layout : 'form',
+ labelWidth : 110,
+ items : [{
+ xtype : 'textfield',
+ fieldLabel : '名称',
+ maxLength : '41',
+ id : 'name',
+ name : 'name',
+ allowBlank : false,
+ anchor : '95%',
+ listeners:{
+ change:function(field,nV,oV){
+ var value = nV.trim();
+ field.setValue(value);
+ }
+ }
+ }]
+ },{
+ columnWidth : 1,
+ layout : 'form',
+ labelWidth : 110,
+ items : [{
+ xtype : 'textfield',
+ fieldLabel : '规格',
+ maxLength : '41',
+ id : 'specification',
+ name : 'specification',
+ allowBlank : true,
+ anchor : '95%'
+ }]
+ },{
+ columnWidth : 1,
+ layout : 'form',
+ labelWidth : 110,
+ items : [{
+ xtype : 'textfield',
+ fieldLabel : '单位转换调整系数',
+ maxLength : '41',
+ id : 'unitConvertCoefficient',
+ name : 'unitConvertCoefficient',
+ allowBlank : true,
+ anchor : '95%'
+ }]
+ },{
+ columnWidth : 1,
+ layout : 'form',
+ labelWidth : 110,
+ items : [{
+ xtype : 'textfield',
+ fieldLabel : '包装规格',
+ maxLength : '41',
+ id : 'packageSpec',
+ name : 'packageSpec',
+ allowBlank : true,
+ anchor : '95%'
+ }]
+ },{
+ columnWidth : 1,
+ layout : 'form',
+ labelWidth : 110,
+ items : [{
+ xtype : 'combo',
+ fieldLabel : "类型",
+ valueField : 'typeName',
+ displayField : 'typeName',
+ store : diposableGooodsStore,
+ forceSelection : true,
+ editable : false,
+ triggerAction : 'all',
+ name : "type",
+ id : "type",
+ value : dType,
+ anchor : '95%',
+ listeners : {
+ select : function(combo , record , index){
+ // 如果类型不为空,并且配置为自动增加外部编码,那么获取下一个编码,并且填上
+ if(!isUndefinedOrNullOrEmpty(combo.value) && autoFillExternalCodeOfDisposableGoods){
+ DiposableGoodsTableManager.getNextExternalCodeOfDisposableGoods(combo.value,function(externalCode){
+ if(!isUndefinedOrNullOrEmpty(externalCode)){
+ top.Ext.getCmp("externalCode").setValue(externalCode);
+ }
+ });
+ }
+ }
+ }
+ }]
+ },{
+ columnWidth : 1,
+ layout : 'form',
+ labelWidth : 110,
+ items : [{
+ xtype : 'combo',
+ fieldLabel : "物品类型",
+ valueField : 'value',
+ displayField : 'value',
+ store : goodsTypeStore,
+ forceSelection : true,
+ allowBlank : false,
+ mode : 'local',
+ triggerAction : 'all',
+ name : "goodsType",
+ id : "goodsType",
+ anchor : '95%'
+ }]
+ },{
+ columnWidth : 1,
+ layout : 'form',
+ labelWidth : 110,
+ items : [{
+ xtype : 'combo',
+ fieldLabel : "类别",
+ valueField : 'name',
+ displayField : 'name',
+ store : new Ext.data.SimpleStore({
+ data:[['一类'],['二类'],['三类']],
+ fields:['name']
+ }),
+ mode : 'local',
+ forceSelection : true,
+ editable : false,
+ triggerAction : 'all',
+ name : "grade",
+ id : "grade",
+ anchor : '95%'
+ }]
+ },{
+ columnWidth : 1,
+ layout : 'form',
+ labelWidth : 110,
+ items : [{
+ xtype : 'combo',
+ fieldLabel : "能否配包",
+ valueField : 'value',
+ displayField : 'value',
+ store : isPartOfTousseMaterialStore,
+ forceSelection : true,
+ allowBlank : false,
+ mode : 'local',
+ triggerAction : 'all',
+ name : "isPartOfTousseMaterial",
+ id : "isPartOfTousseMaterial",
+ anchor : '95%'
+ }]
+ }, {
+ columnWidth : 1,
+ layout : 'form',
+ labelWidth : 110,
+ items : [{
+ xtype : 'combo',
+ fieldLabel : '能否申请',
+ valueField : 'value',
+ displayField : 'value',
+ store : isApplicationMaterialStore,
+ forceSelection : true,
+ allowBlank : false,
+ mode : 'local',
+ triggerAction : 'all',
+ name : "isApplicationMaterial",
+ id : "isApplicationMaterial",
+ anchor : '95%'
+ }]
+ },{
+ columnWidth : 1,
+ layout : 'form',
+ labelWidth : 110,
+ items : [{
+ xtype : 'combo',
+ fieldLabel : '消毒供应中心物品',
+ valueField : 'value',
+ displayField : 'value',
+ store : yesNoStore,
+ forceSelection : true,
+ allowBlank : false,
+ mode : 'local',
+ triggerAction : 'all',
+ name : "isSupplyRoomGoods",
+ id : "isSupplyRoomGoods",
+ anchor : '95%'
+ }]
+ },{
+ columnWidth : 1,
+ layout : 'form',
+ labelWidth : 110,
+ items : [{
+ xtype : 'combo',
+ fieldLabel : '包外标签是否打印',
+ valueField : 'value',
+ displayField : 'value',
+ store : yesNoStore,
+ forceSelection : true,
+ allowBlank : false,
+ mode : 'local',
+ triggerAction : 'all',
+ name : "printInLabel",
+ id : "printInLabel",
+ anchor : '95%'
+ }]
+ },{
+ columnWidth : 1,
+ layout : 'form',
+ labelWidth : 110,
+ items : [{
+ xtype : 'numberfield',
+ fieldLabel : '最小库存',
+ allowDecimals : false,
+ maxLength : '16',
+ id : 'minStorage',
+ name : 'minStorage',
+ anchor : '95%'
+ }]
+ }, {
+ columnWidth : 1,
+ layout : 'form',
+ labelWidth : 110,
+ items : [{
+ xtype : 'numberfield',
+ fieldLabel : '最大库存',
+ allowDecimals : false,
+ maxLength : '16',
+ id : 'maxStorage',
+ name : 'maxStorage',
+ anchor : '95%'
+ }]
+ }, {
+ columnWidth : 1,
+ layout : 'form',
+ labelWidth : 110,
+ items : [{
+ xtype : 'textfield',
+ fieldLabel : '拼音码',
+ id : 'spelling',
+ name : 'spelling',
+ readOnly : true,
+ allowBlank : true,
+ anchor : '95%'
+ }]
+ }, {
+ columnWidth : 1,
+ layout : 'form',
+ labelWidth : 110,
+ items : [{
+ xtype : 'textfield',
+ fieldLabel : '五笔码',
+ id : 'wbCode',
+ name : 'wbCode',
+ readOnly : true,
+ allowBlank : true,
+ anchor : '95%'
+ }]
+ }, {
+ columnWidth : 1,
+ layout : 'form',
+ labelWidth : 110,
+ items : [{
+ xtype : 'textfield',
+ fieldLabel : '外部编码',
+ maxLength : '16',
+ id : 'externalCode',
+ name : 'externalCode',
+ allowBlank : true,
+ anchor : '95%'
+ }]
+ }, {
+ columnWidth : 1,
+ layout : 'form',
+ labelWidth : 110,
+ items : [{
+ xtype : 'numberfield',
+ fieldLabel : '参考价',
+ maxLength : '16',
+ id : 'referencePrice',
+ name : 'referencePrice',
+ allowBlank : false,
+ allowNegative : false,
+ anchor : '95%'
+ }]
+ }, {
+ columnWidth : 1,
+ layout : 'form',
+ labelWidth : 110,
+ items : [{
+ xtype : 'numberfield',
+ fieldLabel : '最小申请数量',
+ maxLength : '16',
+ id : 'minApplyAmount',
+ name : 'minApplyAmount',
+ allowBlank : true,
+ anchor : '95%'
+ }]
+ }, {
+ columnWidth : 1,
+ layout : 'form',
+ labelWidth : 110,
+ items : [{
+ xtype : 'numberfield',
+ fieldLabel : '最大申请数量',
+ maxLength : '16',
+ id : 'maxApplyAmount',
+ name : 'maxApplyAmount',
+ allowBlank : true,
+ anchor : '95%'
+ }]
+ },{
+ columnWidth : 1,
+ layout : 'form',
+ labelWidth : 110,
+ items : [{
+ xtype : 'textfield',
+ fieldLabel : '单位',
+ maxLength : '16',
+ id : 'unit',
+ name : 'unit',
+ allowBlank : true,
+ anchor : '95%'
+ }]
+ }
+ ]
+ },{
+ columnWidth : 0.6,
+ layout : 'form',
+ items : [
+ new top.Ext.grid.GridPanel({
+ id :'batchNumberGrid',
+ store : godownEntryItemStore ,
+ height : 425,
+ width : 485,
+ bodyStyle : 'border:1px solid #afd7af',
+ sm : selectModel,
+ cm : new top.Ext.grid.ColumnModel([selectModel,
+ {header : "id",dataIndex : 'id',hidden : true},
+ {header : "条码",width : 90,dataIndex : 'barcode',menuDisabled:true},
+ {header : "批次",width : 90,dataIndex : 'batchNumber',menuDisabled:true},
+ {header : "价格",width : 50,dataIndex : 'cost',menuDisabled:true},
+ {header : "失效期",width : 90,dataIndex : 'expDate',renderer:myDateFormat,menuDisabled:true},
+ {id:'supplierName',header : "供应商",width : 130,dataIndex : 'supplierName',menuDisabled:true}
+ ]),
+ autoExpandColumn : 'supplierName',
+ frame : false,
+ viewConfig: {forceFit:true},
+ title : '批次列表'
+ })
+ ]
+ }]
+ }],
+ buttons : [{
+ id : 'saveBtn',
+ text : '保存',
+ hidden: true,
+ handler : save
+ },{
+ id : 'cancleBtn',
+ text : '取消',
+ hidden: true,
+ handler : function() {
+ formWindow.close();
+ }
+ },{
+ id : 'print',
+ text : '打印批次',
+ hidden: true,
+ handler : function() {
+ var items = null;
+ var records = top.Ext.getCmp('batchNumberGrid').getSelectionModel().getSelections();
+ if (records.length == 0) {
+ showResult("请选择要打印的批次!");
+ return false;
+ }
+ var goodsName = top.Ext.getCmp('name').getValue();
+
+ for ( var i = 0, len = records.length; i < len; i++) {
+ if(items == null){
+ items = goodsName
+ + ',' + records[i].data.barcode
+ + ',' + myDateFormat(records[i].data.expDate)
+ + ',' + records[i].data.supplierName
+ + ',' + records[i].data.batchNumber;
+ }else {
+ items += ';' + goodsName
+ + ',' + records[i].data.barcode
+ + ',' + myDateFormat(records[i].data.expDate)
+ + ',' + records[i].data.supplierName
+ + ',' + records[i].data.batchNumber;
+ }
+ }
+ top.Ext.getCmp("items").setValue(items);
+ formObj.form.submit({
+ url : WWWROOT + '/disinfectSystem/diposableGoodsAction!printDiposableGoods.do',
+ method : 'POST',
+ waitMsg : '正在保存数据,请稍候',
+ waitTitle : '提交表单',
+ success : function(form, action) {
+ window.close();
+ grid.dwrReload();
+ //打印条码
+ printBarcode(action.result.barcode);
+
+ },
+ failure : function(form, action) {
+ showResult(action.result.message);
+ }
+ });
+ }
+ }]
+ });
+
+ if($Id("parm_s_type").value != ""){
+ top.Ext.getCmp("type").setValue($Id("parm_s_type").value);
+ }
+
+ formWindow = new top.Ext.Window( {
+ id : 'diposableGoodsWin',
+ layout : 'fit',
+ title : '一次性物品信息',
+ width : 850,
+ modal : true,
+ autoHeight : true,
+ border : false,
+ plain : true,
+ items : [ formObj ]
+ });
+ formWindow.show();
+ diposableGooodsStore.load();
+ // 如果类型不为空,并且配置为自动增加外部编码,那么获取下一个编码,并且填上
+ if(!isUndefinedOrNullOrEmpty(dType) && autoFillExternalCodeOfDisposableGoods){
+ DiposableGoodsTableManager.getNextExternalCodeOfDisposableGoods(dType,function(externalCode){
+ if(!isUndefinedOrNullOrEmpty(externalCode)){
+ top.Ext.getCmp("externalCode").setValue(externalCode);
+ }
+ });
+ }
+ if(id != 0){
+ godownEntryItemStore.load();
+ }
+}
+
+function printAmount() {
+ top.Ext.MessageBox.prompt("输入框", "打印数量:", function(bu, txt) {
+ return txt;
+ });
+}
+
+function printBarcode(barcodeStr){
+ if(barcodeStr!=null && barcodeStr.length > 0){
+ top.Ext.Msg.show({
+ title: '输入框',
+ msg: '打印数量:',
+ width: 100,
+ buttons: Ext.MessageBox.OKCANCEL,
+ prompt : true,
+ fn: function(bu, txt) {
+ if(bu == 'ok'){
+ if(isNaN(txt) == false){
+ var godownEntryItem = barcodeStr.split(";");
+ var specification = top.Ext.getCmp('specification').getValue();
+ for(var j = 0 ; j< Number(txt) ; j++){
+ for ( var i = 0; i < godownEntryItem.length; i++) {
+ var resultItem = godownEntryItem[i].split("#&");
+ var name =resultItem[0];
+ var barcode = resultItem[1];
+ var expDate = resultItem[2];
+ var supplierName = resultItem[3];
+ var batchNumber = resultItem[4];
+ printDiposableGoodsInfo(barcode,name,expDate,supplierName,batchNumber,0,specification);
+ }
+ }
+ }else{
+ showResult("打印数量必须是数字,请重新输入!");
+ }
+ }
+ },
+ animEl: 'addAddressBtn',
+ value:'1'
+ });
+ }
+}
+
+function submitForSaveDisposableGoods(){
+ formObj.form.submit( {
+ url : WWWROOT + '/disinfectSystem/diposableGoodsAction!saveDiposableGoods.do',
+ method : 'POST',
+ waitMsg : '正在保存数据,请稍候',
+ waitTitle : '提交表单',
+ success : function(form, action) {
+ var result = Ext.decode(action.response.responseText);
+ if(isUndefinedOrNullOrEmpty(result.errorMessage)){
+ showResult('保存成功');
+ formWindow.close();
+ grid.dwrReload();
+ }else{
+ showResult('保存出错, ' + result.errorMessage);
+ top.Ext.getCmp('saveBtn').enable();
+ }
+ },
+ failure : function(form, action) {
+ showResult('保存出错');
+ top.Ext.getCmp('saveBtn').enable();
+ }
+ });
+}
+function validateAndSubmit(){
+ Ext.Ajax.request({
+ url : WWWROOT + '/disinfectSystem/diposableGoodsAction!validate.do',
+ params : {
+ validateId : top.Ext.getCmp('id').getValue(),
+ valifateName:top.Ext.getCmp('name').getValue(),
+ specification:top.Ext.getCmp('specification').getValue()
+ },
+ success : function(response, options) {
+ var result = Ext.decode(response.responseText);
+ if(result.stauts==1){
+ var originalGoodsType = top.Ext.getCmp("originalGoodsType").getValue();
+ var goodsType = top.Ext.getCmp("goodsType").getValue();
+ var orginalName = top.Ext.getCmp("orginalName").getValue();
+ var orginalSpecification = top.Ext.getCmp("orginalSpecification").getValue();
+ var name = top.Ext.getCmp("name").getValue();
+ var specification = top.Ext.getCmp("specification").getValue();
+ var msg = '';
+ if(!stringLooksEquals(orginalName,name) && !stringLooksEquals(orginalSpecification,specification)){
+ msg = "是否确定修改一次性物品名称和规格?"
+ }else if(!stringLooksEquals(orginalName,name)){
+ msg = "是否确定修改一次性物品名称?"
+ }else if(!stringLooksEquals(orginalSpecification,specification)){
+ msg = "是否确定修改一次性物品规格?"
+ }
+ if(!stringLooksEquals(originalGoodsType,goodsType)){
+ msg += "是否确定更改物品类型?"
+ }
+ if(msg == ''){
+ submitForSaveDisposableGoods();
+ return;
+ }
+ top.Ext.MessageBox.confirm("请确认",msg,
+ function(button, text) {
+ if ("yes" == button){
+ submitForSaveDisposableGoods();
+ }else{
+ top.Ext.getCmp('saveBtn').enable();
+ }
+ });
+ }else{
+ showResult(result.message);
+ top.Ext.getCmp('saveBtn').enable();
+ }
+ },
+ failure : function(response, options) {
+ var result = Ext.decode(response.responseText);
+ showResult(result.cause);
+ }
+ });
+}
+
+function save(){
+ //if(!form.getForm().isValid()){
+ if(!formObj.getForm().isValid()){
+ showResult('请正确填写表单各值');
+ return false;
+ }
+ var unitConvertCoefficient = top.Ext.getCmp('unitConvertCoefficient').getValue();
+ if(unitConvertCoefficient != null && unitConvertCoefficient != ""){
+ if(unitConvertCoefficient <= 0){
+ showResult("单位转换调整系数必须大于0!");
+ top.Ext.getCmp('unitConvertCoefficient').setValue("");
+ top.Ext.getCmp('unitConvertCoefficient').focus();
+ return false;
+ }
+ }
+
+ var max = top.Ext.getCmp('maxStorage').getValue();
+ var min = top.Ext.getCmp('minStorage').getValue();
+ var minApply = top.Ext.getCmp('minApplyAmount').getValue();
+ var maxApply = top.Ext.getCmp('maxApplyAmount').getValue();
+ if(typeof max == 'number' && typeof min == 'number'){
+ if(min>max){
+ showResult('最小库存不能大于最大库存');
+ top.Ext.getCmp('minStorage').focus();
+ return false;
+ }
+ if(minApply > maxApply){
+ showResult('最小申请数不能大于最大申请数');
+ top.Ext.getCmp('minApplyAmount').focus();
+ return false;
+ }
+ }
+ this.disable();
+ validateAndSubmit();
+}
+
+function printBatchNum(barcodeStr){
+ if(barcodeStr!=null && barcodeStr.length > 0){
+ Ext.Msg.show({
+ title: '输入框',
+ msg: '打印数量:',
+ width: 100,
+ buttons: Ext.MessageBox.OKCANCEL,
+ prompt : true,
+ fn: function(bu, txt) {
+ if(bu == 'ok'){
+ if(isNaN(txt) == false){
+ var godownEntryItem = barcodeStr.split(";");
+ for(var j = 0 ; j< Number(txt) ; j++){
+ for ( var i = 0; i < godownEntryItem.length; i++) {
+ var resultItem = godownEntryItem[i].split("#&");
+ var name =resultItem[0];
+ var barcode = resultItem[1];
+ var expDate = resultItem[2];
+ var supplierName = resultItem[3];
+ var batchNumber = resultItem[4];
+ var specification = resultItem[5];
+ printDiposableGoodsInfo(barcode,name,expDate,supplierName,batchNumber,0,specification);
+ }
+ }
+ }else{
+ showResult("打印数量必须是数字,请重新输入!");
+ }
+ }
+ },
+ animEl: 'addAddressBtn',
+ value:'1'
+ });
+ }
+}
+function onStorageRecordDetail(grid){
+ var records = grid.getSelectionModel().getSelections();
+ if(records.length == 0){
+ showResult("请选择一次性物品");
+ return;
+ }
+ if(records.length != 1){
+ showResult("只能选择一个一次性物品");
+ return;
+ }
+
+ var storageRecord = new StorageRecord();
+ storageRecord.setDisposableGoodsId(records[0].data['id']);
+ storageRecord.showDetail();
+}
+//打印批次条码
+function printBatchStockBarcode(grid){
+ var records = grid.getSelectionModel().getSelections();
+ if(records.length == 0){
+ showResult("请选择要打印批次条码的物品");
+ }else{
+ var ids = "";
+ for(var i = 0,len=records.length;i
+ + | +