Compare commits
	
		
			No commits in common. "ebdfeb7a33a72210da7a5edbc919bc4bb0471cfe" and "5ce7b64172c8d5d2cfd7b251abf713d0f5e5d514" have entirely different histories.
		
	
	
		
			ebdfeb7a33
			...
			5ce7b64172
		
	
		| 
						 | 
				
			
			@ -10,7 +10,7 @@ const AREA = {
 | 
			
		|||
    cardHeadBtnArea: 'card_head', //卡片表头按钮区域
 | 
			
		||||
    cardBodyBtnArea: 'card_body', //卡片表体按钮区域
 | 
			
		||||
    cardBodyInnerBtnArea: 'card_body_inner', //卡片表体操作按钮区域
 | 
			
		||||
    // borrowMaterialDialog: 'NCTable_83c3abf9', //借料弹窗
 | 
			
		||||
    borrowMaterialDialog: 'NCTable_83c3abf9', //借料弹窗
 | 
			
		||||
    borrowList: 'borrow_list', //借料弹窗页面编码
 | 
			
		||||
    BORROW_DLG: 'BorrowDlg' //借料入库
 | 
			
		||||
};
 | 
			
		||||
| 
						 | 
				
			
			@ -71,13 +71,13 @@ const CARD_BTN = {
 | 
			
		|||
    Refresh: 'Refresh',//刷新
 | 
			
		||||
    drop_more: 'drop_more',
 | 
			
		||||
 | 
			
		||||
    pushrzmes: 'pushrzmes',//推送锐制
 | 
			
		||||
    pushrzmes:'pushrzmes',//推送锐制
 | 
			
		||||
 | 
			
		||||
    PickmDelivery: 'PickmDelivery',//领料
 | 
			
		||||
    PickmDeliveryWithSet: 'PickmDeliveryWithSet',//成套领料
 | 
			
		||||
    PickmReDeliveryWithSet: 'PickmReDeliveryWithSet',//补成套领料
 | 
			
		||||
    ToReqPickm: 'ToReqPickm',//备料
 | 
			
		||||
 | 
			
		||||
    
 | 
			
		||||
    toOtherWarehouse: 'toOtherWarehouse',//其他入库
 | 
			
		||||
    DirectTrans: 'DirectTrans',//直接备料
 | 
			
		||||
    PickmBackDelivery: 'PickmBackDelivery',//退料
 | 
			
		||||
| 
						 | 
				
			
			@ -203,7 +203,7 @@ const URL = {
 | 
			
		|||
    setBackDeliverQueryURL: '/nccloud/mmpac/pickm/setbackdeliverquery.do',
 | 
			
		||||
    setBackDeliverComputURL: '/nccloud/mmpac/pickm/setbackdelivercomput.do',
 | 
			
		||||
    checkToReqpickm: '/nccloud/mmpac/pickm/checktoreqpickm.do',
 | 
			
		||||
    checkToDirectTrans: '/nccloud/mmpac/pickm/checktoDirectTrans.do',
 | 
			
		||||
    checkToDirectTrans:'/nccloud/mmpac/pickm/checktoDirectTrans.do',
 | 
			
		||||
    toReqpickm: '/reqpickm',
 | 
			
		||||
    noItemDeliverQueryURL: '/nccloud/mmpac/pickm/noitemdeliverquery.do',
 | 
			
		||||
    noItemDeliverURL: '/nccloud/mmpac/pickm/noitemdeliver.do',
 | 
			
		||||
| 
						 | 
				
			
			@ -212,13 +212,13 @@ const URL = {
 | 
			
		|||
    replaceQueryURL: '/nccloud/mmpac/pickm/replaceQuery.do',
 | 
			
		||||
    replaceBodyQueryURL: '/nccloud/mmpac/pickm/replaceBodyQuery.do',
 | 
			
		||||
    replaceDoURL: '/nccloud/mmpac/pickm/replace.do',
 | 
			
		||||
    replaceAutoMatchURL: '/nccloud/mmpac/pickm/replaceAutoMatch.do',
 | 
			
		||||
    replaceAutoMatchURL:'/nccloud/mmpac/pickm/replaceAutoMatch.do',
 | 
			
		||||
    deleteLineURL: '/nccloud/mmpac/pickm/deleteline.do',
 | 
			
		||||
    queryByCondURL: '/nccloud/mmpac/pickm/queryByCond.do',
 | 
			
		||||
    convertOtherIn: '/nccloud/mmpac/pickm/convertOtherIn.do',
 | 
			
		||||
    pickmItemsQuery: '/nccloud/mmpac/pickm/pickmItemsQuery.do',
 | 
			
		||||
    pickmIdsQuery: '/nccloud/mmpac/pickm/pickmByIdsQuery.do',
 | 
			
		||||
    pushrzmsURL: '/nccloud/mmpac/pickm/pushrzmes.do'
 | 
			
		||||
    queryByCondURL:'/nccloud/mmpac/pickm/queryByCond.do',
 | 
			
		||||
    convertOtherIn:'/nccloud/mmpac/pickm/convertOtherIn.do',
 | 
			
		||||
    pickmItemsQuery:'/nccloud/mmpac/pickm/pickmItemsQuery.do',
 | 
			
		||||
    pickmIdsQuery:'/nccloud/mmpac/pickm/pickmByIdsQuery.do',
 | 
			
		||||
    pushrzmsURL:'/nccloud/mmpac/pickm/pushrzmes.do'
 | 
			
		||||
};
 | 
			
		||||
 | 
			
		||||
const tabURL = '/list';
 | 
			
		||||
| 
						 | 
				
			
			@ -259,7 +259,6 @@ const FIELD = {
 | 
			
		|||
    cbastunitid: 'cbastunitid',
 | 
			
		||||
    vbatchcode: 'vbatchcode',
 | 
			
		||||
    vsrcid: 'vsrcid', //来源单据id
 | 
			
		||||
    pk_group: 'pk_group', //集团
 | 
			
		||||
};
 | 
			
		||||
//表头不可修改字段
 | 
			
		||||
const headDisableFields = [
 | 
			
		||||
| 
						 | 
				
			
			@ -482,24 +481,24 @@ let clearItems = [
 | 
			
		|||
    'vfree10'
 | 
			
		||||
];
 | 
			
		||||
const headfixAssts = [
 | 
			
		||||
    'cvendorid',
 | 
			
		||||
    'cvendorvid',
 | 
			
		||||
    'cproductorid',
 | 
			
		||||
    'cprojectid',
 | 
			
		||||
    'ccustomerid',
 | 
			
		||||
    'ccustomervid'
 | 
			
		||||
    // 'cqualitylevelid',
 | 
			
		||||
    //'cffileid'
 | 
			
		||||
	'cvendorid',
 | 
			
		||||
	'cvendorvid',
 | 
			
		||||
	'cproductorid',
 | 
			
		||||
	'cprojectid',
 | 
			
		||||
	'ccustomerid',
 | 
			
		||||
	'ccustomervid'
 | 
			
		||||
	// 'cqualitylevelid',
 | 
			
		||||
	//'cffileid'
 | 
			
		||||
];
 | 
			
		||||
const bodyfixAssts = [
 | 
			
		||||
    'cbvendorid',
 | 
			
		||||
    'cbvendorvid',
 | 
			
		||||
    'cbproductorid',
 | 
			
		||||
    'cbprojectid',
 | 
			
		||||
    'cbcustomerid',
 | 
			
		||||
    'cbcustomervid'
 | 
			
		||||
    // 'cbqualitylevelid',
 | 
			
		||||
    //'cbffileid'
 | 
			
		||||
	'cbvendorid',
 | 
			
		||||
	'cbvendorvid',
 | 
			
		||||
	'cbproductorid',
 | 
			
		||||
	'cbprojectid',
 | 
			
		||||
	'cbcustomerid',
 | 
			
		||||
	'cbcustomervid'
 | 
			
		||||
	// 'cbqualitylevelid',
 | 
			
		||||
	//'cbffileid'
 | 
			
		||||
];
 | 
			
		||||
const headCustAndSupFild = {
 | 
			
		||||
    ccustomerid: 'ccustomerid',
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
| 
						 | 
				
			
			@ -1,15 +1,6 @@
 | 
			
		|||
import {AREA, FIELD} from "../../../constance";
 | 
			
		||||
import {AREA} from "../../../constance";
 | 
			
		||||
 | 
			
		||||
export default async function headAfterEvent(props, moduleId, key, value, changedrows, i) {
 | 
			
		||||
    // console.log('value = ', value);
 | 
			
		||||
    if (key == FIELD.vbatchcode) {
 | 
			
		||||
        if (value.length > 0) {
 | 
			
		||||
            let firstElement = value[0];
 | 
			
		||||
            let vbatchcode = firstElement.values.vbatchcode.value;
 | 
			
		||||
            let pk_batchcode = firstElement.values.pk_batchcode.value;
 | 
			
		||||
            props.editTable.setValByKeyAndIndex(moduleId, i, key, {value: vbatchcode, display: vbatchcode});
 | 
			
		||||
            props.editTable.setValByKeyAndIndex(moduleId, i, 'pk_batchcode', {value: pk_batchcode, display: null});
 | 
			
		||||
        }
 | 
			
		||||
 | 
			
		||||
    }
 | 
			
		||||
    // let headData = props.editTable.getAllData(AREA.borrowList, true);
 | 
			
		||||
    // this.props.setHeadDatas(headData);
 | 
			
		||||
}
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
| 
						 | 
				
			
			@ -1,19 +1,14 @@
 | 
			
		|||
import {FIELD} from "../../../constance";
 | 
			
		||||
import {processBatchCodeItem} from "../../../../wr/card/util/batchCodeUtil";
 | 
			
		||||
 | 
			
		||||
export default function headBeforeEvent(props, moduleId, item, index, value, record) {
 | 
			
		||||
    let key = item.attrcode;
 | 
			
		||||
    let editFields = ['vbatchcode'];
 | 
			
		||||
    let editFields = ['freplacetype'];
 | 
			
		||||
    if (!editFields.includes(key)) {
 | 
			
		||||
        return false;
 | 
			
		||||
    } else if (key == FIELD.vbatchcode) {
 | 
			
		||||
        let cmaterialvid = props.editTable.getValByKeyAndIndex(moduleId, index, FIELD.cmaterialvid).value;
 | 
			
		||||
        //物料为空直接返回false 不可编辑
 | 
			
		||||
        if (!cmaterialvid) {
 | 
			
		||||
            toast({content: '缺少物料编码', color: 'warning'});
 | 
			
		||||
    } else if (key == 'freplacetype') {
 | 
			
		||||
        //以替代的备料计划表体不能修改替代类型
 | 
			
		||||
        let replaceInfo = props.editTable.getValByKeyAndIndex(moduleId, index, 'freplaceinfo').value;
 | 
			
		||||
        if (replaceInfo == 2) {
 | 
			
		||||
            return false;
 | 
			
		||||
        }
 | 
			
		||||
        processBatchCodeItem.call(this, props, moduleId, key, record, '4A', false);
 | 
			
		||||
    }
 | 
			
		||||
    return true;
 | 
			
		||||
}
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
| 
						 | 
				
			
			@ -2,7 +2,7 @@ import React, {Component} from 'react';
 | 
			
		|||
import {base, createPage, high} from 'nc-lightapp-front';
 | 
			
		||||
import {initTemplate} from './init';
 | 
			
		||||
import {initLang} from '../../../../../mmpub/mmpub/pub/tool/multiLangUtil';
 | 
			
		||||
import {headAfterEvent, headBeforeEvent} from './events';
 | 
			
		||||
import {headAfterEvent} from './events';
 | 
			
		||||
import {DIALOGCODE, AREA} from "../../constance";
 | 
			
		||||
 | 
			
		||||
const {Refer} = high;
 | 
			
		||||
| 
						 | 
				
			
			@ -39,7 +39,7 @@ class PickmBorrowDlg extends Component {
 | 
			
		|||
                    // height: 100,
 | 
			
		||||
                    // onRowClick: this.onRowClick.bind(this),
 | 
			
		||||
                    // onRowDoubleClick: this.onRowDoubleClick.bind(this),
 | 
			
		||||
                    onBeforeEvent: headBeforeEvent.bind(this),
 | 
			
		||||
                    // onBeforeEvent: headBeforeEvent.bind(this),
 | 
			
		||||
                    onAfterEvent: headAfterEvent.bind(this),
 | 
			
		||||
                    isAddRow: false,
 | 
			
		||||
                    showCheck: true
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
		Reference in New Issue