Merge remote-tracking branch 'origin/main'
This commit is contained in:
commit
043986bdc2
|
|
@ -170,6 +170,23 @@ export default function (props) {
|
||||||
}
|
}
|
||||||
);
|
);
|
||||||
props.button.setUploadConfig(PMO_CARD_BUTTON.Import, excelimportconfig);
|
props.button.setUploadConfig(PMO_CARD_BUTTON.Import, excelimportconfig);
|
||||||
|
// 导入序列号
|
||||||
|
let excelimportconfig1 = excelImportconfig(
|
||||||
|
props,
|
||||||
|
PMO_LIST.excelOutput.module,
|
||||||
|
'pmo_sernio',
|
||||||
|
true,
|
||||||
|
'',
|
||||||
|
{
|
||||||
|
appcode: PMO_LIST.appcode,
|
||||||
|
pagecode: '50080000_import1'
|
||||||
|
},
|
||||||
|
() => {
|
||||||
|
//导入按钮的回调
|
||||||
|
buttonClick.call(this, props, PMO_CARD_BUTTON.Import);
|
||||||
|
}
|
||||||
|
);
|
||||||
|
props.button.setUploadConfig(PMO_CARD_BUTTON.ImportNo, excelimportconfig1);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -622,6 +622,11 @@ export default function clickBtn(props, id, text, record, index) {
|
||||||
let importC = importClick.bind(this, props, id);
|
let importC = importClick.bind(this, props, id);
|
||||||
return importC(props);
|
return importC(props);
|
||||||
}
|
}
|
||||||
|
case PMO_CARD_BUTTON.ImportNo: {
|
||||||
|
//导入序列号
|
||||||
|
let importC = importClick.bind(this, props, id);
|
||||||
|
return importC(props);
|
||||||
|
}
|
||||||
case PMO_CARD_BUTTON.PushToPlm: {
|
case PMO_CARD_BUTTON.PushToPlm: {
|
||||||
let billId = props.form.getFormItemsValue(formId, HEADATTRCODE.CPMOHID).value;
|
let billId = props.form.getFormItemsValue(formId, HEADATTRCODE.CPMOHID).value;
|
||||||
// 传递设计任务
|
// 传递设计任务
|
||||||
|
|
|
||||||
|
|
@ -377,5 +377,10 @@ export default function clickBtn(props, id, text, record, index) {
|
||||||
let importC = importClick.bind(this, props, id);
|
let importC = importClick.bind(this, props, id);
|
||||||
return importC(props);
|
return importC(props);
|
||||||
}
|
}
|
||||||
|
case PMO_LIST_BUTTON.ImportNo: {
|
||||||
|
//导入序列号
|
||||||
|
let importC = importClick.bind(this, props, id);
|
||||||
|
return importC(props);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -2,23 +2,24 @@
|
||||||
* 模板初始化
|
* 模板初始化
|
||||||
*/
|
*/
|
||||||
|
|
||||||
import { base, ajax, toast, cacheTools, getGlobalStorage, removeGlobalStorage, cardCache } from 'nc-lightapp-front';
|
import {base, ajax, toast, cacheTools, getGlobalStorage, removeGlobalStorage, cardCache} from 'nc-lightapp-front';
|
||||||
import { PMO_LIST, PMO_CARD, DATECONST, PMO_LIST_BUTTON, HEADATTRCODE } from '../../pmoconst';
|
import {PMO_LIST, PMO_CARD, DATECONST, PMO_LIST_BUTTON, HEADATTRCODE, PMO_CARD_BUTTON} from '../../pmoconst';
|
||||||
import buttonClick from '../btnclicks/buttonClick';
|
import buttonClick from '../btnclicks/buttonClick';
|
||||||
import { buttonController, btnClickController } from '../viewControl';
|
import {buttonController, btnClickController} from '../viewControl';
|
||||||
import { transtypeUtils, setPsndocShowLeavePower, setRefShowDisabledData } from '../../../../../mmpub/mmpub/pub/tool';
|
import {transtypeUtils, setPsndocShowLeavePower, setRefShowDisabledData} from '../../../../../mmpub/mmpub/pub/tool';
|
||||||
import { getLangByResId } from '../../../../../mmpub/mmpub/pub/tool/multiLangUtil';
|
import {getLangByResId} from '../../../../../mmpub/mmpub/pub/tool/multiLangUtil';
|
||||||
import { conf as unitConf } from '../../../../../uapbd/refer/org/FactoryGridRef/index';
|
import {conf as unitConf} from '../../../../../uapbd/refer/org/FactoryGridRef/index';
|
||||||
//excel导入工具类(平台提供)
|
//excel导入工具类(平台提供)
|
||||||
import excelImportconfig from '../../../../../uap/common/components/excelImportconfig';
|
import excelImportconfig from '../../../../../uap/common/components/excelImportconfig';
|
||||||
|
|
||||||
let tableId = PMO_LIST.tableId;
|
let tableId = PMO_LIST.tableId;
|
||||||
let searchId = PMO_LIST.searchId;
|
let searchId = PMO_LIST.searchId;
|
||||||
let listpageid = PMO_LIST.pageid;
|
let listpageid = PMO_LIST.pageid;
|
||||||
const linkItem = PMO_LIST.vbillcode;
|
const linkItem = PMO_LIST.vbillcode;
|
||||||
const cpmohid = HEADATTRCODE.CPMOHID;
|
const cpmohid = HEADATTRCODE.CPMOHID;
|
||||||
const deleteUrl = PMO_LIST.deleteURL;
|
const deleteUrl = PMO_LIST.deleteURL;
|
||||||
const { getDefData, setDefData } = cardCache;
|
const {getDefData, setDefData} = cardCache;
|
||||||
export default function(props) {
|
export default function (props) {
|
||||||
//查询按钮使用
|
//查询按钮使用
|
||||||
this.props.createUIDom(
|
this.props.createUIDom(
|
||||||
{
|
{
|
||||||
|
|
@ -50,6 +51,7 @@ export default function(props) {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
);
|
);
|
||||||
|
|
||||||
function modifierMeta(props, meta) {
|
function modifierMeta(props, meta) {
|
||||||
let noshowOrgFileds = [
|
let noshowOrgFileds = [
|
||||||
HEADATTRCODE.APPROVER,
|
HEADATTRCODE.APPROVER,
|
||||||
|
|
@ -68,14 +70,14 @@ export default function(props) {
|
||||||
item.isMultiSelectedEnabled = true;
|
item.isMultiSelectedEnabled = true;
|
||||||
//主组织权限过滤
|
//主组织权限过滤
|
||||||
item.queryCondition = () => {
|
item.queryCondition = () => {
|
||||||
return { GridRefActionExt: 'nccloud.web.mmpub.pub.ref.AppPermissionOrgRefFilter' };
|
return {GridRefActionExt: 'nccloud.web.mmpub.pub.ref.AppPermissionOrgRefFilter'};
|
||||||
};
|
};
|
||||||
} else if (item.attrcode == HEADATTRCODE.PK_ORG_V) {
|
} else if (item.attrcode == HEADATTRCODE.PK_ORG_V) {
|
||||||
//设置可多选
|
//设置可多选
|
||||||
item.isMultiSelectedEnabled = true;
|
item.isMultiSelectedEnabled = true;
|
||||||
//主组织权限过滤
|
//主组织权限过滤
|
||||||
item.queryCondition = () => {
|
item.queryCondition = () => {
|
||||||
return { GridRefActionExt: 'nccloud.web.mmpub.pub.ref.AppPermissionOrgVidRefFilter' };
|
return {GridRefActionExt: 'nccloud.web.mmpub.pub.ref.AppPermissionOrgVidRefFilter'};
|
||||||
};
|
};
|
||||||
} else if (item.attrcode == HEADATTRCODE.CPLANFACTORYID) {
|
} else if (item.attrcode == HEADATTRCODE.CPLANFACTORYID) {
|
||||||
//设置可多选
|
//设置可多选
|
||||||
|
|
@ -102,13 +104,13 @@ export default function(props) {
|
||||||
} else if (item.attrcode == HEADATTRCODE.CTRANTYPEID) {
|
} else if (item.attrcode == HEADATTRCODE.CTRANTYPEID) {
|
||||||
//设置交易类型
|
//设置交易类型
|
||||||
item.queryCondition = () => {
|
item.queryCondition = () => {
|
||||||
return { parentbilltype: PMO_LIST.billType };
|
return {parentbilltype: PMO_LIST.billType};
|
||||||
};
|
};
|
||||||
} else if (item.attrcode == 'mm_mo.cmaterialid' || item.attrcode == 'mm_mo.cmaterialvid') {
|
} else if (item.attrcode == 'mm_mo.cmaterialid' || item.attrcode == 'mm_mo.cmaterialvid') {
|
||||||
item.isShowUnit = true;
|
item.isShowUnit = true;
|
||||||
item.queryCondition = () => {
|
item.queryCondition = () => {
|
||||||
let pk_org = props.search.getSearchValByField(searchId, HEADATTRCODE.PK_ORG);
|
let pk_org = props.search.getSearchValByField(searchId, HEADATTRCODE.PK_ORG);
|
||||||
let condition = { productmode: 1 };
|
let condition = {productmode: 1};
|
||||||
pk_org =
|
pk_org =
|
||||||
pk_org != null
|
pk_org != null
|
||||||
? pk_org.value.firstvalue.includes(',') ? null : pk_org.value.firstvalue
|
? pk_org.value.firstvalue.includes(',') ? null : pk_org.value.firstvalue
|
||||||
|
|
@ -131,7 +133,7 @@ export default function(props) {
|
||||||
item.queryCondition = () => {
|
item.queryCondition = () => {
|
||||||
let data = props.search.getSearchValByField(searchId, HEADATTRCODE.PK_ORG);
|
let data = props.search.getSearchValByField(searchId, HEADATTRCODE.PK_ORG);
|
||||||
data = data != null ? (data.value.firstvalue.includes(',') ? null : data.value.firstvalue) : null;
|
data = data != null ? (data.value.firstvalue.includes(',') ? null : data.value.firstvalue) : null;
|
||||||
return { pk_org: data, busifuncode: 'fa' };
|
return {pk_org: data, busifuncode: 'fa'};
|
||||||
};
|
};
|
||||||
} else if (item.attrcode == 'mm_mo.cwkid') {
|
} else if (item.attrcode == 'mm_mo.cwkid') {
|
||||||
//生产线
|
//生产线
|
||||||
|
|
@ -158,7 +160,7 @@ export default function(props) {
|
||||||
item.queryCondition = () => {
|
item.queryCondition = () => {
|
||||||
let data = props.search.getSearchValByField(searchId, HEADATTRCODE.PK_ORG);
|
let data = props.search.getSearchValByField(searchId, HEADATTRCODE.PK_ORG);
|
||||||
data = data != null ? (data.value.firstvalue.includes(',') ? null : data.value.firstvalue) : null;
|
data = data != null ? (data.value.firstvalue.includes(',') ? null : data.value.firstvalue) : null;
|
||||||
return { pk_org: data, busifuncode: 'fa' };
|
return {pk_org: data, busifuncode: 'fa'};
|
||||||
};
|
};
|
||||||
} else if (item.attrcode == 'mm_mo.cffileid') {
|
} else if (item.attrcode == 'mm_mo.cffileid') {
|
||||||
item.queryCondition = () => {
|
item.queryCondition = () => {
|
||||||
|
|
@ -229,14 +231,14 @@ export default function(props) {
|
||||||
//用户档案的人,不需要显示业务单元
|
//用户档案的人,不需要显示业务单元
|
||||||
let data = props.search.getSearchValByField(searchId, HEADATTRCODE.PK_ORG);
|
let data = props.search.getSearchValByField(searchId, HEADATTRCODE.PK_ORG);
|
||||||
data = data != null ? (data.value.firstvalue.includes(',') ? null : data.value.firstvalue) : null;
|
data = data != null ? (data.value.firstvalue.includes(',') ? null : data.value.firstvalue) : null;
|
||||||
return { pk_org: data };
|
return {pk_org: data};
|
||||||
};
|
};
|
||||||
} else {
|
} else {
|
||||||
item.isShowUnit = true;
|
item.isShowUnit = true;
|
||||||
item.queryCondition = () => {
|
item.queryCondition = () => {
|
||||||
let data = props.search.getSearchValByField(searchId, HEADATTRCODE.PK_ORG);
|
let data = props.search.getSearchValByField(searchId, HEADATTRCODE.PK_ORG);
|
||||||
data = data != null ? (data.value.firstvalue.includes(',') ? null : data.value.firstvalue) : null;
|
data = data != null ? (data.value.firstvalue.includes(',') ? null : data.value.firstvalue) : null;
|
||||||
return { pk_org: data };
|
return {pk_org: data};
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
@ -290,6 +292,7 @@ export default function(props) {
|
||||||
meta[tableId].items.push(porCol);
|
meta[tableId].items.push(porCol);
|
||||||
return meta;
|
return meta;
|
||||||
}
|
}
|
||||||
|
|
||||||
function setQueryDefault(props, meta) {
|
function setQueryDefault(props, meta) {
|
||||||
let searchVal = cacheTools.get('searchVal');
|
let searchVal = cacheTools.get('searchVal');
|
||||||
if (!searchVal) {
|
if (!searchVal) {
|
||||||
|
|
@ -297,7 +300,7 @@ export default function(props) {
|
||||||
{
|
{
|
||||||
field: 'mm_mo.tplanstarttime',
|
field: 'mm_mo.tplanstarttime',
|
||||||
oprtype: 'between',
|
oprtype: 'between',
|
||||||
value: { firstvalue: '#day(0)#', secondvalue: '#day(0)#' }
|
value: {firstvalue: '#day(0)#', secondvalue: '#day(0)#'}
|
||||||
}
|
}
|
||||||
]);
|
]);
|
||||||
}
|
}
|
||||||
|
|
@ -341,7 +344,7 @@ export default function(props) {
|
||||||
this.setState({
|
this.setState({
|
||||||
currentTab: PMO_LIST.all
|
currentTab: PMO_LIST.all
|
||||||
});
|
});
|
||||||
let rowsData = { rows: [] };
|
let rowsData = {rows: []};
|
||||||
if (res.data.currentGrid && res.data.currentGrid[tableId]) {
|
if (res.data.currentGrid && res.data.currentGrid[tableId]) {
|
||||||
rowsData = res.data.currentGrid[tableId];
|
rowsData = res.data.currentGrid[tableId];
|
||||||
}
|
}
|
||||||
|
|
@ -354,6 +357,7 @@ export default function(props) {
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
function toggleShow() {
|
function toggleShow() {
|
||||||
//处理生产大屏数据穿透
|
//处理生产大屏数据穿透
|
||||||
process4dashboard.call(this);
|
process4dashboard.call(this);
|
||||||
|
|
@ -405,7 +409,7 @@ export default function(props) {
|
||||||
this.setState({
|
this.setState({
|
||||||
currentTab: PMO_LIST.all
|
currentTab: PMO_LIST.all
|
||||||
});
|
});
|
||||||
let rowsData = { rows: [] };
|
let rowsData = {rows: []};
|
||||||
if (res.data.currentGrid && res.data.currentGrid[tableId]) {
|
if (res.data.currentGrid && res.data.currentGrid[tableId]) {
|
||||||
rowsData = res.data.currentGrid[tableId];
|
rowsData = res.data.currentGrid[tableId];
|
||||||
}
|
}
|
||||||
|
|
@ -418,11 +422,12 @@ export default function(props) {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (linkkey) {
|
if (linkkey) {
|
||||||
this.props.setUrlParam({ [PMO_LIST.LINK_KEY]: null });
|
this.props.setUrlParam({[PMO_LIST.LINK_KEY]: null});
|
||||||
cacheTools.remove(linkkey);
|
cacheTools.remove(linkkey);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
//初始化Excel导入配置
|
//初始化Excel导入配置
|
||||||
function initExcelImportConfig(props) {
|
function initExcelImportConfig(props) {
|
||||||
//导入主子表
|
//导入主子表
|
||||||
|
|
@ -442,5 +447,22 @@ export default function(props) {
|
||||||
}
|
}
|
||||||
);
|
);
|
||||||
props.button.setUploadConfig(PMO_LIST_BUTTON.Import, excelimportconfig);
|
props.button.setUploadConfig(PMO_LIST_BUTTON.Import, excelimportconfig);
|
||||||
|
// 导入序列号
|
||||||
|
let excelimportconfig1 = excelImportconfig(
|
||||||
|
props,
|
||||||
|
PMO_LIST.excelOutput.module,
|
||||||
|
'pmo_sernio', // XML文件名称
|
||||||
|
true,
|
||||||
|
'',
|
||||||
|
{
|
||||||
|
appcode: PMO_LIST.appcode,
|
||||||
|
pagecode: '50080000_import1'
|
||||||
|
},
|
||||||
|
() => {
|
||||||
|
//导入按钮的回调
|
||||||
|
buttonClick.call(this, props, PMO_CARD_BUTTON.Import);
|
||||||
|
}
|
||||||
|
);
|
||||||
|
props.button.setUploadConfig(PMO_CARD_BUTTON.ImportNo, excelimportconfig1);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -4,14 +4,16 @@
|
||||||
"uap/common/components/ApproveDetail",
|
"uap/common/components/ApproveDetail",
|
||||||
"uap/common/components/NCUploader",
|
"uap/common/components/NCUploader",
|
||||||
"uap/common/components/approvalTrans",
|
"uap/common/components/approvalTrans",
|
||||||
"ic/ic/components/billReserve"
|
"ic/ic/components/billReserve",
|
||||||
|
"uap/common/components/excelImportconfig"
|
||||||
],
|
],
|
||||||
"dependjs": [
|
"dependjs": [
|
||||||
"../../../../uap/common/components/codeConfigModal/index.js",
|
"../../../../uap/common/components/codeConfigModal/index.js",
|
||||||
"../../../../uap/common/components/ApproveDetail/index.js",
|
"../../../../uap/common/components/ApproveDetail/index.js",
|
||||||
"../../../../uap/common/components/NCUploader/index.js",
|
"../../../../uap/common/components/NCUploader/index.js",
|
||||||
"../../../../uap/common/components/approvalTrans/index.js",
|
"../../../../uap/common/components/approvalTrans/index.js",
|
||||||
"../../../../ic/ic/components/billReserve/index.js"
|
"../../../../ic/ic/components/billReserve/index.js",
|
||||||
|
"../../../../uap/common/components/excelImportconfig/index.js"
|
||||||
],
|
],
|
||||||
"report": true
|
"report": true
|
||||||
}
|
}
|
||||||
|
|
@ -175,6 +175,7 @@ const PMO_LIST_BUTTON = {
|
||||||
pmobcdirectprint: 'PMOBCDirectPrint', //直接打印条码
|
pmobcdirectprint: 'PMOBCDirectPrint', //直接打印条码
|
||||||
pmobcprint: 'PMOBCPrint', //打印条码
|
pmobcprint: 'PMOBCPrint', //打印条码
|
||||||
Import: 'Import', //导入
|
Import: 'Import', //导入
|
||||||
|
ImportNo: 'ImportNo', //导入序列号
|
||||||
ExportTem: 'ExportTem' //导出
|
ExportTem: 'ExportTem' //导出
|
||||||
};
|
};
|
||||||
const PMO_CARD_BUTTON = {
|
const PMO_CARD_BUTTON = {
|
||||||
|
|
@ -307,6 +308,7 @@ const PMO_CARD_BUTTON = {
|
||||||
grand_g1: 'grand_g1',
|
grand_g1: 'grand_g1',
|
||||||
oresetno: 'OResetno', //联副产品重新排号
|
oresetno: 'OResetno', //联副产品重新排号
|
||||||
Import: 'Import', //导入
|
Import: 'Import', //导入
|
||||||
|
ImportNo: 'ImportNo', //导入序列号
|
||||||
ExportTem: 'ExportTem', //导出
|
ExportTem: 'ExportTem', //导出
|
||||||
PushToPlm: 'pushToPlm' //导出
|
PushToPlm: 'pushToPlm' //导出
|
||||||
};
|
};
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue