Array.prototype.包含 = function(value){
return this.indexOf(value)>=0;
}
// var 订单 = {"数据源模板名称":"NKSC2","门头样式":"无","门框工艺":"机拉框"};
console.info(">>>>>>>>>") ;
console.info(aaa()) ;
console.info("<<<<<<<<") ;
function aaa(){
var 订单 = {"内扇亮窗":"无","罗马柱立柱样式":"无","门洞宽":"850-1100","外开启扇下封板包边宽":430,"插销扇木皮颜色":"描金","加铁框":0,"右立框展开高":2615,"门套线":"无","外开启扇前面板展开高":2204,"亮窗花包边":"标准","亮窗花玻璃高":340,"方舟模板id":19,"门框喷涂面积":3838355,"亮窗支架宽":864,"门扇喷涂面积":4337436,"玻璃槽":"整片","右立框展开宽":540,"门单价":669,"外开启扇下封板包边高":1680,"contactAddress":"客户:杨勇; 电话:13403969100; 地址:付庄","开向":"内右开","颜色类型":"氟碳漆","外开启扇喷涂面积":4337436,"outWarehouseDate":"2024-12-14 00:00:00","外开启扇前面板展开宽":1059,"外开启扇下封板展开高":354,"门洞高":"2280-3800","门扇描金":"描金","productId":2245285,"门等级":"普配","其它备注":"亮窗带两边装饰件。","庭院门铜钉数量":"","亮窗花成型宽":855,"圆盘数量":"无","外开启扇上封板":"无","外开启扇门芯花包边宽":2645,"墙厚":"260-270","外边扇门芯花包边宽":310,"高档非标门铝卡工艺":"无","门价格":739,"外开启扇前压花边距宽":315,"内插销扇结构加价":15597,"中码头展开宽":415,"门高(定尺)":"2100","下码头展开高":881,"颜色":"ZS-07","外开启扇类型":"实体","门扇下扑边":"有","门扇折叠":"无","外开启扇后压花边距宽":262,"包边加价":50,"门扇厚度":"10公分厚扑边","外开启扇玻璃宽":380,"亮窗花等分数量":"整片","非钢质门扇数量":0,"反凸板是否":"正常板","外开启扇前压花边距高":262,"外开启扇下花展开宽":1020,"包边造型":"6号包边","左立框展开高":2615,"doorSeriesName":"一键下单产品","produceStatus":"OUT_WAREHOUSE","主门扇花型":"TA-248","底框":"不锈钢复合底框","门扇数量":1,"内开启扇下封板":"普通框","doorTemplateId":324,"外开启扇后压花边距高":198,"外开启扇门芯花玻璃位置":"无","外开启扇成型高":1992,"订单类型":"2023高档丰收系列","inWarehouseDate":"2024-12-08 00:00:00","合页":"丰收豪华合页","包装":"不包装","门宽加价":20,"亮窗花玻璃位置":"外白内镀膜","罗马柱":"无","栅栏立柱":"机拉框","attachFields":{"门扇描金":"描金","门扇下扑边":"有","庭院门铜钉数量":"","圆盘数量":"无","铜钉颜色":"","高档非标门铝卡工艺":"无","前面板防爆板工艺":"否","反凸板是否":"正常板","拉丝工艺":"不拉丝","分包数量":1,"底框工艺":"机拉框","圆盘款式":"无","后面板防爆板工艺":"否"},"主扇花型":"无","铜钉行数":1278,"计价面积(毫米)":2425000,"外开启扇成型宽":845,"中码头展开高":881,"门套":"无","拼板铰前展开高":5,"外包边右":"有","包边开向":"外包内开","批门":"否","门头样式":"无","锁具":"忠恒6.7cm圆头防插单锁","压纹":"否","门框包边":"外包边","外插销扇结构加价":12293,"商标":"金双诚","门备注":"左不包边。","inWarehouseTime":"2024-12-08 08:54:10","门档线":1,"门框厚度":260,"亮窗花型类别":"古典花","拉手手柄":"活拉手","亮窗大花数量":354,"外购件":"有","亮窗":"有","不锈钢材质":"待处理","铜钉颜色":"","亮窗花布局":"整片","外包边上":"有","左立框展开宽":540,"doorType":"GDSA","复合框样式":"是","门框工艺":"自折框","serialNo":"GDSA-70-12-24","拉丝工艺":"不拉丝","外开启扇后面板展开宽":954,"开启扇木皮颜色":"描金","内包边样式":"无","亮窗花边造型":"方管","数据源模板名称":"GDSA","宽":970,"门扇后面板板材厚度":"正常","下码头展开宽":375,"门扇板材类型":"蜂窝纸","后面板防爆板工艺":"否","亮窗花型":"TA-GH70","上码头展开宽":540,"approvalDate":"2024-11-25 00:00:00","外边扇下封板包边宽":380,"铜钉列数":215,"亮窗花成型高":340,"内边扇门中门":"否","外开启扇后门扇花型":"TA-248","outWarehouseTime":"2024-12-14 15:54:57","前面板防爆板工艺":"否","每扇合页数量":3,"门套板":"无","门店样品":"否","外开启扇前门扇花型":"TA-248","分包数量":"1","拉手款式":"1#拉手","外边扇下封板包边高":381,"底框高":55,"底框工艺":"机拉框","罗马柱门头样式":"无","extendFields":"null","压槽":"无","数据源":"金双诚","extendFieldsDesc":"null","外开启扇后面板展开高":2100,"基础价格":669,"门高":2100,"门框板材厚度":"1.2mm锌铁合金板","竖筋数量":881,"上码头展开高":1201,"门扇板材厚度":"0.7mm","狮子头":"无","外开启扇封头长度":842,"外插销扇门芯花包边高":1231,"approvalTime":"2024-11-25 17:11:41","亮窗片数":1,"套板样式":"55","总高":2500,"外包边左":"无","门框类型":"机拉框","亮窗花玻璃宽":855,"外插销扇门芯花包边宽":1250,"doorSeriesId":76,"圆盘款式":"无","payStatus":"PAID","拼板铰前展开宽":10};
/*机拉框设备从南至北1-13序号对应产品*/
var NK = (订单.数据源模板名称).indexOf("NK");
var GDK = (订单.数据源模板名称).indexOf("GDK");
var MT = (订单.门头样式).indexOf("门头");
if (订单.门框工艺 == '机拉框') {
console.info("nk值") ;
console.info(NK) ;
if (NK == 0) {
if ((订单.罗马柱 == '无' && MT <= 0) && 订单.包边造型 == '8号包边' && 订单.门框厚度 == '280') {
return 1;
}
console.info(订单.罗马柱) ;
console.info(订单.包边造型) ;
console.info(订单.门框厚度) ;
if ((订单.罗马柱 == '无' && MT <= 0) && 订单.包边造型 == '8号包边' && 订单.门框厚度 == '260') {
return 2;
}
if ((订单.罗马柱 == '有' || MT > 0) ) {
return 3;
}
}
if (['GDSA'].包含(订单.数据源模板名称)) {
if (订单.包边造型 == '6号包边' && 订单.门框厚度 == '260') {
return 5;
}
if (订单.包边造型 == '6号包边' && 订单.门框厚度 == '135' && ['外左开', '外右开'].包含(订单.开向)) {
return 8;
}
if (订单.包边造型 == '6号包边' && 订单.门框厚度 == '135' && ['内左开', '内右开'].包含(订单.开向)) {
return 9;
}
}
if (["GDSB1", "GDSB2", "GDSC1", "GDSC2", "GDFA", "GDFB1", "GDFB2", "GDFC1", "GDFC2"].包含(订单.数据源模板名称)) {
if ((订单.罗马柱 == '有' || MT > 0) && 订单.门框厚度 == '260') {
return 4;
}
if ((订单.罗马柱 == '有' || MT > 0) && 订单.门框厚度 == '280') {
return 4;
}
if ((订单.罗马柱 == '无' && MT <= 0) && 订单.包边造型 == '6号包边' && 订单.门框厚度 == '260') {
return 10;
}
if ((订单.罗马柱 == '无' && MT <= 0) && 订单.包边造型 == '3号包边' && 订单.门框厚度 == '280') {
return 13;
}
}
}
return 0
}
console