webpackJsonp([4],{

/***/ 1213:
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
Object.defineProperty(__webpack_exports__, "__esModule", { value: true });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "AqlPkgDetailPageModule", function() { return AqlPkgDetailPageModule; });
/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__angular_core__ = __webpack_require__(0);
/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1_ionic_angular__ = __webpack_require__(14);
/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__aql_pkg_detail__ = __webpack_require__(1467);
/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__components_components_module__ = __webpack_require__(775);
/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4__ngx_translate_core__ = __webpack_require__(257);
/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5__ncinga_sp_nsp_app_core_dist__ = __webpack_require__(53);
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
    var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
    if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
    else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
    return c > 3 && r && Object.defineProperty(target, key, r), r;
};






var AqlPkgDetailPageModule = /** @class */ (function () {
    function AqlPkgDetailPageModule() {
    }
    AqlPkgDetailPageModule = __decorate([
        Object(__WEBPACK_IMPORTED_MODULE_0__angular_core__["NgModule"])({
            declarations: [
                __WEBPACK_IMPORTED_MODULE_2__aql_pkg_detail__["a" /* AqlPkgDetailPage */],
            ],
            imports: [
                __WEBPACK_IMPORTED_MODULE_5__ncinga_sp_nsp_app_core_dist__["g" /* CoreModule */],
                __WEBPACK_IMPORTED_MODULE_3__components_components_module__["a" /* ComponentsModule */],
                __WEBPACK_IMPORTED_MODULE_1_ionic_angular__["i" /* IonicPageModule */].forChild(__WEBPACK_IMPORTED_MODULE_2__aql_pkg_detail__["a" /* AqlPkgDetailPage */]),
                __WEBPACK_IMPORTED_MODULE_4__ngx_translate_core__["b" /* TranslateModule */].forChild()
            ],
        })
    ], AqlPkgDetailPageModule);
    return AqlPkgDetailPageModule;
}());

//# sourceMappingURL=aql-pkg-detail.module.js.map

/***/ }),

/***/ 1467:
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return AqlPkgDetailPage; });
/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__angular_core__ = __webpack_require__(0);
/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1_ionic_angular__ = __webpack_require__(14);
/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2_ngx_logger__ = __webpack_require__(7);
/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__ncinga_sp_nsp_app_core_dist_providers_navigation_manager__ = __webpack_require__(80);
/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4__providers_aql_data_provider__ = __webpack_require__(779);
/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5__aql_pkg_detail_template__ = __webpack_require__(1468);
/* harmony import */ var __WEBPACK_IMPORTED_MODULE_6__ncinga_sp_nsp_app_core_dist_providers_business_context__ = __webpack_require__(40);
/* harmony import */ var __WEBPACK_IMPORTED_MODULE_7__aql_events_aql_event__ = __webpack_require__(1469);
/* harmony import */ var __WEBPACK_IMPORTED_MODULE_8__ncinga_sp_nsp_app_core_dist__ = __webpack_require__(53);
/* harmony import */ var __WEBPACK_IMPORTED_MODULE_9__ncinga_sp_nsp_app_core_dist_providers_app_events__ = __webpack_require__(65);
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
    var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
    if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
    else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
    return c > 3 && r && Object.defineProperty(target, key, r), r;
};
var __metadata = (this && this.__metadata) || function (k, v) {
    if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
};










var AqlPkgDetailPage = /** @class */ (function () {
    function AqlPkgDetailPage(logger, navigationProvider, navParams, aqlDataProvider, businessContext, applicationContext, appState) {
        var _this = this;
        this.logger = logger;
        this.navigationProvider = navigationProvider;
        this.navParams = navParams;
        this.aqlDataProvider = aqlDataProvider;
        this.businessContext = businessContext;
        this.applicationContext = applicationContext;
        this.appState = appState;
        this.nextPage = '';
        this.current_pkg_details_list = [];
        this.new_pkg_detail = {};
        this.fieldArray = [];
        this.newAttribute = {};
        this.final_pkg_detail = {};
        this.tools = {
            line: true,
            menu: true,
            shift: true,
            user: true
        };
        this.row_item_description = [];
        this.current_color_list = [
            { name: 'Red' }, { name: 'Green' }, { name: 'Blue' }, { name: 'Black' },
        ];
        this.current_size_list = [
            { name: 'S' }, { name: 'M' }, { name: 'L' }, { name: 'XL' },
        ];
        this.pkg_grid_data = {};
        this.current_bussness_context = {};
        this.current_bussiness_key = '';
        this.current_bussness_context = [{ 'name': 'Buyer', 'value': 'H&M' },
            { 'name': 'Season', 'value': 'SP18' },
            { 'name': 'PO', 'value': '#909009' },
            { 'name': 'Style', 'value': 'AJ8902' },
            {
                'name': 'Color', 'value': 'Green'
            }
        ];
        this.currentPageConfig = this.navParams.get('conf');
        this.currentShift = this.applicationContext.getCurrentShift().id;
        this.current_line = this.applicationContext.getCurrentSubject().id;
        // this.current_bussness_context = this.businessContext.getCurrentContext();
        this.logger.debug(this.currentPageConfig);
        this.currentPageData = this.currentPageConfig['components_descriptor'];
        this.left_side = this.currentPageData.left_side;
        if (this.left_side.comp_name === 'package_detail_comp') {
            // this.addRow();
            if (this.left_side.comp_type === 'add_rows') {
                this.prepareAddRowdata();
            }
            else if (this.left_side.comp_type === 'data_grid') {
                this.prepareDataGriddata();
            }
            this.prepareDisplayData();
            this.right_side = this.currentPageData.right_side;
            // load page header and footer;
            this.currentPageheader = this.currentPageConfig['title'];
            this.currentPagebuttons = this.currentPageConfig['view_controles'];
            // check whether next page available
            if (this.currentPageConfig['next_view_ref'] !== 'EXIT') {
                this.nextPage = this.currentPageConfig['next_view_ref'];
            }
            else {
                this.nextPage = 'page_order_end';
            }
            this.appState.subscribe(__WEBPACK_IMPORTED_MODULE_9__ncinga_sp_nsp_app_core_dist_providers_app_events__["a" /* APPEvents */].APP_SUBJECT_CHANGE, function (res) {
                _this.logger.debug(res, 'LINE CHANGE ');
                var event = res;
                _this.lineChangeOccured(event);
            });
            this.appState.subscribe(__WEBPACK_IMPORTED_MODULE_9__ncinga_sp_nsp_app_core_dist_providers_app_events__["a" /* APPEvents */].APP_SHIFT_CHANGE, function (res) {
                _this.logger.debug(res, 'SHIFT CHANGE');
                var event = res;
                _this.shiftChangeOccured(event);
            });
            this.appState.subscribe(__WEBPACK_IMPORTED_MODULE_9__ncinga_sp_nsp_app_core_dist_providers_app_events__["a" /* APPEvents */].APP_BUSINESS_CTX_CHANGE, function (res) {
                _this.logger.debug(res, 'BUSSINESS CXT CHANGE');
                var event = res;
                _this.bussinessContextChangeOccured(event);
            });
        }
    }
    AqlPkgDetailPage.prototype.prepareAddRowdata = function () {
        var _this = this;
        if (this.left_side.data_type === 'color_size') {
            if (this.current_color_list.length > 0 && this.current_size_list.length > 0) {
                this.current_color_list.forEach(function (itemColor, indexColor) {
                    _this.current_size_list.forEach(function (itemSize, indexSize) {
                        var temp = {};
                        temp['name'] = itemColor.name + ' / ' + itemSize.name;
                        temp['color'] = itemColor.name;
                        temp['size'] = itemSize.name;
                        _this.row_item_description.push(temp);
                    });
                });
            }
        }
        else if (this.left_side.data_type === 'color_only') {
            this.current_color_list.forEach(function (itemColor, indexColor) {
                var temp = {};
                temp['name'] = itemColor.name;
                temp['color'] = itemColor.name;
                temp['size'] = '';
                _this.row_item_description.push(temp);
            });
        }
    };
    AqlPkgDetailPage.prototype.prepareDataGriddata = function () {
        var _this = this;
        if (this.left_side.data_type === 'color_size') {
            this.current_color_list.forEach(function (clrItem, clrIndex) {
                _this.pkg_grid_data[clrItem.name] = {};
                _this.current_size_list.forEach(function (sizeItem, sizeIndex) {
                    _this.pkg_grid_data[clrItem.name][sizeItem.name] = 0;
                });
            });
        }
        else if (this.left_side.data_type === 'color_only') {
            this.current_color_list.forEach(function (clrItem, clrIndex) {
                _this.pkg_grid_data[clrItem.name] = 0;
            });
        }
    };
    AqlPkgDetailPage.prototype.prepareDisplayData = function () {
        var _this = this;
        this.current_bussiness_key = this.current_line;
        this.current_bussness_context.forEach(function (item, index) {
            _this.current_bussiness_key = _this.current_bussiness_key + '_' + item.value;
        });
        this.logger.debug(this.aqlDataProvider.aql_pkg_detail_line_data[this.current_bussiness_key]);
        if (this.left_side.comp_type === 'add_rows') {
            if (this.aqlDataProvider.aql_pkg_detail_line_data.hasOwnProperty(this.current_bussiness_key)) {
                this.current_pkg_details_list = this.aqlDataProvider.aql_pkg_detail_line_data[this.current_bussiness_key];
            }
            else {
                this.addRow();
            }
        }
        else if (this.left_side.comp_type === 'data_grid') {
            if (this.aqlDataProvider.aql_pkg_detail_line_data.hasOwnProperty(this.current_bussiness_key)) {
                this.pkg_grid_data = this.aqlDataProvider.aql_pkg_detail_line_data[this.current_bussiness_key];
            }
            else {
                this.pkg_grid_data = {};
                this.prepareDataGriddata();
            }
        }
    };
    AqlPkgDetailPage.prototype.shiftChangeOccured = function (event) {
        this.currentShift = event;
    };
    AqlPkgDetailPage.prototype.lineChangeOccured = function (event) {
        if (this.left_side.comp_type === 'add_rows') {
            this.aqlDataProvider.aql_pkg_detail_line_data[this.current_bussiness_key] = this.current_pkg_details_list;
        }
        else if (this.left_side.comp_type === 'data_grid') {
            this.aqlDataProvider.aql_pkg_detail_line_data[this.current_bussiness_key] = this.pkg_grid_data;
        }
        this.current_line = event;
        this.current_pkg_details_list = [];
        this.pkg_grid_data = {};
        this.prepareDisplayData();
        this.logger.debug(this.aqlDataProvider.aql_pkg_detail_line_data);
    };
    AqlPkgDetailPage.prototype.bussinessContextChangeOccured = function (event) {
        this.current_bussness_context = event;
        this.logger.debug(this.current_bussness_context, 'new business cxt ');
        if (this.left_side.comp_type === 'add_rows') {
            this.current_pkg_details_list = [];
            this.addRow();
        }
        else if (this.left_side.comp_type === 'data_grid') {
            this.pkg_grid_data = {};
            this.prepareDataGriddata();
        }
    };
    AqlPkgDetailPage.prototype.addFieldValue = function () {
        this.fieldArray.push(this.newAttribute);
        this.newAttribute = {};
        // this.logger.info(this.fieldArray);
    };
    AqlPkgDetailPage.prototype.deleteFieldValue = function (index) {
        this.fieldArray.splice(index, 1);
    };
    AqlPkgDetailPage.prototype.addRow = function () {
        var temp = {};
        temp['pass_count'] = 0;
        temp['fail_count'] = 0;
        temp['pass_selected'] = false;
        temp['fail_selected'] = false;
        temp['pass_count_selected'] = false;
        temp['fail_count_selected'] = false;
        temp['color'] = '';
        temp['size'] = '';
        this.current_pkg_details_list.push(temp);
    };
    AqlPkgDetailPage.prototype.changeStatus = function (index, data) {
        this.current_pkg_details_list[index]['status'] = data;
        // this.logger.info(this.current_pkg_details_list);
    };
    AqlPkgDetailPage.prototype.changeStatusandCount = function (index, data, sampleQty) {
        this.current_pkg_details_list[index]['status'] = data;
        var current_total = this.current_pkg_details_list[index]['pass_count'] + this.current_pkg_details_list[index]['fail_count'];
        // this.logger.info(current_total);
        if (current_total < sampleQty) {
            if (data === 'pass') {
                this.current_pkg_details_list[index]['pass_count'] = this.current_pkg_details_list[index]['pass_count'] + 1;
            }
            if (data === 'fail') {
                this.current_pkg_details_list[index]['fail_count'] = this.current_pkg_details_list[index]['fail_count'] + 1;
            }
        }
        this.current_pkg_details_list[index]['latest'] = data;
        // this.logger.info(this.current_pkg_details_list);
    };
    AqlPkgDetailPage.prototype.undoCount = function (index) {
        if (this.current_pkg_details_list[index]['latest'] === 'pass') {
            this.current_pkg_details_list[index]['pass_count'] = this.current_pkg_details_list[index]['pass_count'] - 1;
        }
        else if (this.current_pkg_details_list[index]['latest'] === 'fail') {
            this.current_pkg_details_list[index]['fail_count'] = this.current_pkg_details_list[index]['fail_count'] - 1;
        }
        this.current_pkg_details_list[index]['latest'] = 'none';
    };
    AqlPkgDetailPage.prototype.deleteRow = function (index) {
        this.current_pkg_details_list.splice(index, 1);
    };
    AqlPkgDetailPage.prototype.onValueChange = function (type, value) {
        this.logger.debug(value);
        if (type === 'qty') {
            this.total_qty = this.total_qty + value;
        }
    };
    AqlPkgDetailPage.prototype.mainPassFailButtonsClicked = function (finalStatus) {
        var _this = this;
        this.logger.debug(this.current_pkg_details_list);
        this.logger.debug(this.pkg_grid_data);
        this.logger.debug(typeof this.current_bussness_context);
        var package_items = [];
        var total_qty = 0;
        if (this.left_side.comp_type === 'add_rows' && this.left_side.data_type === 'color_only') {
            this.current_pkg_details_list.forEach(function (item, idx) {
                if (item.hasOwnProperty('qty') && item.qty > 0) {
                    var currItem = new __WEBPACK_IMPORTED_MODULE_7__aql_events_aql_event__["b" /* AqlPkgItem */]({
                        color: item.color,
                        size: item.size,
                        qty: item.qty,
                        is_fail: -1,
                        item_issue: []
                    });
                    package_items.push(currItem);
                    total_qty = parseInt(item.qty) + total_qty;
                }
            });
        }
        if (this.left_side.comp_type === 'add_rows' && this.left_side.data_type === 'color_size') {
            this.current_pkg_details_list.forEach(function (item, idx) {
                if (item.hasOwnProperty('qty') && item.qty > 0) {
                    var str = item.color;
                    var list = str.split('/');
                    var currItem = new __WEBPACK_IMPORTED_MODULE_7__aql_events_aql_event__["b" /* AqlPkgItem */]({
                        color: list[0],
                        size: list[1],
                        qty: item.qty,
                        is_fail: -1,
                        item_issue: []
                    });
                    package_items.push(currItem);
                    total_qty = parseInt(item.qty) + total_qty;
                }
            });
        }
        else if (this.left_side.comp_type === 'data_grid' && this.left_side.data_type === 'color_only') {
            this.current_color_list.forEach(function (clrItem, clrIdx) {
                if (_this.pkg_grid_data[clrItem.name] > 0) {
                    var currItem = new __WEBPACK_IMPORTED_MODULE_7__aql_events_aql_event__["b" /* AqlPkgItem */]({
                        color: clrItem.name,
                        size: '',
                        qty: _this.pkg_grid_data[clrItem.name],
                        is_fail: -1,
                        item_issue: []
                    });
                    package_items.push(currItem);
                    total_qty = parseInt(_this.pkg_grid_data[clrItem.name]) + total_qty;
                }
            });
        }
        else if (this.left_side.comp_type === 'data_grid' && this.left_side.data_type === 'color_size') {
            this.current_color_list.forEach(function (clrItem, clrIdx) {
                _this.current_size_list.forEach(function (sizeItem, sizeIndex) {
                    if (_this.pkg_grid_data[clrItem.name][sizeItem.name] > 0) {
                        var currItem = new __WEBPACK_IMPORTED_MODULE_7__aql_events_aql_event__["b" /* AqlPkgItem */]({
                            color: clrItem.name,
                            size: sizeItem.name,
                            qty: _this.pkg_grid_data[clrItem.name][sizeItem.name],
                            is_fail: -1,
                            item_issue: []
                        });
                        package_items.push(currItem);
                        total_qty = parseInt(_this.pkg_grid_data[clrItem.name][sizeItem.name]) + total_qty;
                    }
                });
            });
        }
        var currentAqlEvent = new __WEBPACK_IMPORTED_MODULE_7__aql_events_aql_event__["a" /* AqlEvent */]({
            ty: 'category',
            nm: 'aql',
            v1: 1,
            cv: 1,
            package_items: package_items,
            status: finalStatus,
            total_qty: total_qty,
            shift: this.currentShift,
            line: this.current_line,
            package_issue: []
        });
        this.logger.debug(currentAqlEvent);
        var bussiness_cxt_list = {};
        this.current_bussness_context.forEach(function (item, index) {
            bussiness_cxt_list[item.name] = item.value;
        });
        this.logger.debug(bussiness_cxt_list);
        var output = {};
        output['event'] = currentAqlEvent;
        output['data'] = bussiness_cxt_list;
        var time = new Date();
        var display_date = time.toLocaleString('en-US', { hour: 'numeric', minute: 'numeric', hour12: true });
        output['time'] = display_date;
        this.aqlDataProvider.aql_data_captured_list.push(output);
        this.logger.debug(output);
        this.navigationProvider.exitToRoot({});
    };
    AqlPkgDetailPage.prototype.incompletePkg = function () {
        /*this.final_pkg_detail ['status'] = '';
         this.final_pkg_detail['data'] = this.current_pkg_details_list;

         this.final_pkg_detail ['qty'] = '';
         this.final_pkg_detail ['time'] = 'time';
         this.final_pkg_detail ['po'] = 'PO7788';
         this.final_pkg_detail ['style'] = 'style';
         this.final_pkg_detail['buyer'] = 'nike';
         this.logger.info(this.final_pkg_detail);

         this.aqlDataProvider.aql_incomplete_list.push(this.final_pkg_detail);

         this.logger.debug(this.aqlDataProvider.aql_incomplete_list);
         this.navigationProvider.exitToRoot({});*/
        this.logger.debug(this.pkg_grid_data);
    };
    AqlPkgDetailPage = __decorate([
        Object(__WEBPACK_IMPORTED_MODULE_1_ionic_angular__["h" /* IonicPage */])(),
        Object(__WEBPACK_IMPORTED_MODULE_0__angular_core__["Component"])({
            selector: 'page-aql-pkg-detail',
            template: __WEBPACK_IMPORTED_MODULE_5__aql_pkg_detail_template__["a" /* PKG_DETAIL_TEMPLATE */],
        }),
        __metadata("design:paramtypes", [__WEBPACK_IMPORTED_MODULE_2_ngx_logger__["b" /* NGXLogger */], __WEBPACK_IMPORTED_MODULE_3__ncinga_sp_nsp_app_core_dist_providers_navigation_manager__["a" /* NavigationManager */], __WEBPACK_IMPORTED_MODULE_1_ionic_angular__["n" /* NavParams */],
            __WEBPACK_IMPORTED_MODULE_4__providers_aql_data_provider__["a" /* AqlDataProvider */], __WEBPACK_IMPORTED_MODULE_6__ncinga_sp_nsp_app_core_dist_providers_business_context__["a" /* BusinessContext */],
            __WEBPACK_IMPORTED_MODULE_8__ncinga_sp_nsp_app_core_dist__["c" /* ApplicationContext */], __WEBPACK_IMPORTED_MODULE_8__ncinga_sp_nsp_app_core_dist__["d" /* ApplicationService */]])
    ], AqlPkgDetailPage);
    return AqlPkgDetailPage;
}());

/*this.final_pkg_detail ['status'] = finalStatus;
 this.final_pkg_detail['data'] = this.current_pkg_details_list;

 let tot_qty = 0;
 this.current_pkg_details_list.forEach((item, index) => {
 tot_qty = parseInt(item.qty) + tot_qty;
 });
 this.final_pkg_detail ['qty'] = tot_qty;

 let time = new Date();

 let display_date = time.toLocaleString('en-US', {hour:      'numeric', minute:      'numeric', hour12:      true});
 this.final_pkg_detail ['time'] = display_date;
 this.final_pkg_detail ['po'] = 'PO7788';
 this.final_pkg_detail ['style'] = '1234';
 this.final_pkg_detail['buyer'] = 'nike';
 this.logger.info(this.final_pkg_detail);

 this.aqlDataProvider.aql_complete_list.push(this.final_pkg_detail);*/
//# sourceMappingURL=aql-pkg-detail.js.map

/***/ }),

/***/ 1468:
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return PKG_DETAIL_TEMPLATE; });
/**
 * Created by Paramee Gunethilake on 6/4/2018.
 */
var PKG_DETAIL_TEMPLATE = "\n\n\n<ion-header>\n\n<ion-navbar color=\"c22\">\n<common-main-header [title]=\"'Package Details'\" [tools]=\"tools\"></common-main-header>\n</ion-navbar>\n\n</ion-header>\n\n\n<ion-content padding>\n\n    <ion-grid class=\"main-grid\">\n<ion-row class=\"summary-row\">\n        <ion-col class=\"summary-col\">\n            <core-domain-header></core-domain-header>\n        </ion-col>\n    </ion-row>\n <ion-row class=\"main-data-row\">\n\n <ion-grid>\n        <ion-row class=cont-wraper>\n\n        <ion-col col-9 *ngIf=\"left_side.comp_type === 'add_rows'\" class=\"pkg-detail-col\">\n\n                <ion-row class=\"pkg-hdr\">\n                    <div>Package Details</div>\n                   <!-- <button ion-button class=\"incom-btn\" (click)=\"incompletePkg()\"> Incomplete </button>-->\n                </ion-row>\n\n                <ion-row class=tol-qty>\n                    <span>Total QTY</span><span class=\"count\"></span>\n                </ion-row>\n\n                <div class=\"pkg-detail-lst\">\n                <ion-row *ngFor=\"let itemList of this.current_pkg_details_list ; let i= index\" class=\"pkg-detail-row\">\n\n                    <ion-col *ngFor=\"let singleItem of this.left_side.comp_data\" class=\"input-col\">\n                        <ion-col *ngIf=\"singleItem.type === 'dropdown'\" class=\"pkg-detail-dropdown-col\">\n                            <ion-row class=\"inpt-lbl\"> {{singleItem.header}}</ion-row>\n                            <ion-row>\n                                <ion-select [(ngModel)]=\"itemList[singleItem.header_data]\"\n                                           >\n                                    <ion-option *ngFor=\"let single of row_item_description\"\n                                                value=\"{{single.name}}\">\n                                                {{single.name}}\n                                    </ion-option>\n                                </ion-select>\n\n                            </ion-row>\n                        </ion-col>\n\n                        <ion-col *ngIf=\"singleItem.type === 'input'\" class=\"pkg-detail-input-col\">\n                            <ion-row class=\"inpt-lbl\">{{singleItem.header}}</ion-row>\n                            <ion-row>\n                                <ion-input [(ngModel)]=\"itemList[singleItem.header_data]\" type=\"number\"\n                                           (keyup)=\"onValueChange(singleItem.header_data ,\n                                           itemList[singleItem.header_data])\"\n                                           placeholder=\" \">\n\n                                </ion-input>\n                            </ion-row>\n                        </ion-col>\n\n\n                        <ion-col *ngIf=\"singleItem.type === 'pass_button' && singleItem.button_type ==='pass_fail_button_only'\"\n                        class=\"pkg-detail-button-col\">\n\n                            <button ion-button\n                                     [ngClass]=\"{ 'green_outline_btn':itemList.pass_selected == false,\n                                    'green_color_btn': itemList.pass_selected == true}\"\n                                    (click)=\"changeStatus(i,'pass');\n                                    itemList.pass_selected = !itemList.pass_selected ;\n                                    itemList.fail_selected = false\">\n                                    Pass\n                            </button>\n\n                        </ion-col>\n\n                        <ion-col *ngIf=\"singleItem.type === 'fail_button' && singleItem.button_type ==='pass_fail_button_only'\"\n                        class=\"pkg-detail-button-col\">\n\n                            <button ion-button\n                                    [ngClass]=\"{  'red_outline_btn':itemList.fail_selected == false,\n                                    'red_color_btn': itemList.fail_selected == true}\"\n                                    (click)=\"changeStatus(i,'fail');\n                                    itemList.fail_selected = !itemList.fail_selected ;\n                                    itemList.pass_selected = false \">\n                                    Fail\n                            </button>\n\n                        </ion-col>\n\n                        <ion-col\n                          *ngIf=\"singleItem.type === 'pass_count_button' &&\n                          singleItem.button_type ==='pass_fail_button_with_count_and_classification'\" class=\"pkg-detail-button-col\">\n\n\n                            <button ion-button\n                                    [ngClass]=\"{ 'green_outline_btn':itemList.pass_selected == false,\n                                    'green_color_btn': itemList.pass_selected == true}\"\n\n                                    (click)=\"changeStatusandCount(i,'pass',itemList.sample);itemList.pass_selected = true\">\n                               Pass &nbsp; &nbsp;\n                                <span class=\"sm-btn-count\">{{itemList.pass_count}}</span>\n                            </button>\n                        </ion-col>\n\n                        <ion-col\n                                *ngIf=\"singleItem.type === 'fail_count_button' &&\n                                singleItem.button_type ==='pass_fail_button_with_count_and_classification'\"\n                                class=\"pkg-detail-button-col\">\n\n\n                            <button ion-button\n                                    [ngClass]=\"{  'red_outline_btn':itemList.fail_selected == false,\n                                    'red_color_btn': itemList.fail_selected == true}\"\n\n                                    (click)=\"changeStatusandCount(i,'fail',itemList.sample);\n                                    itemList.fail_selected = true\">\n                                fail  &nbsp; &nbsp;\n                                <span class=\"sm-btn-count\" >{{itemList.fail_count}}</span>\n                            </button>\n                        </ion-col>\n\n                        <ion-col *ngIf=\"singleItem.type === 'button' && singleItem.button_type ==='undo_button'\"\n                         class=\"pkg-detail-button-col undo-btn\">\n                            <button ion-button class=\"undo-button\" (click)=\"undoCount(i)\"> <ion-icon name=\"undo\">\n                            </ion-icon> </button>\n                        </ion-col>\n                    </ion-col>\n\n                    <ion-col class=\"del-col\">\n                        <div></div>\n                        <button ion-button (click)=\"deleteRow(i)\" class=\"\"> <ion-icon name=\"trash\"></ion-icon></button>\n                    </ion-col>\n                </ion-row>\n                </div>\n\n               <ion-row justify-content-end class=\"add-row-row\">\n                    <div></div>\n                    <button ion-button class=\"addrowButton\" (click)=\"addRow()\">\n                    <ion-icon name=\"add\"></ion-icon>  &nbsp;  add row</button>\n                </ion-row>\n              </ion-col>\n         <ion-col col-md-9 col-12 *ngIf=\"left_side.comp_type === 'data_grid' && left_side.data_type === 'color_size'\"\n         class=\"pkg-detail-col\">\n\n               <ion-row class=\"pkg-hdr\">\n                    <div>Package Details</div>\n                   <!-- <button ion-button class=\"incom-btn\" (click)=\"incompletePkg()\"> Incomplete </button>-->\n                </ion-row>\n\n                <ion-row class=tol-qty>\n                   <!-- <span>Total QTY</span><span class=\"count\">100</span>-->\n                </ion-row>\n                <ion-grid class=\"data-grid\">\n                <ion-row  class=\"data-grid-size-header-row\">\n                <ion-col class=\"data-grid-size-header-col\" col-3></ion-col>\n                 <ion-col *ngFor=\"let sizeItem of current_size_list\" class=\"data-grid-size-header-col\">\n                {{sizeItem.name}}\n                 </ion-col>\n                </ion-row>\n                <ion-row class='data-grid-data-rows'   *ngFor=\"let colorItem of current_color_list\" >\n                <ion-col class='data-grid-data-col col-hdr' col-3>{{colorItem.name}}</ion-col>\n                <ion-col>\n                 <ion-row>\n                 <ion-col *ngFor=\"let sizeItem of current_size_list\"  class='data-grid-data-col' >\n                <ion-input type=\"number\" [(ngModel)]=\"pkg_grid_data[colorItem.name][sizeItem.name]\"></ion-input>\n</ion-col>\n                   </ion-row>\n</ion-col>\n               </ion-row>\n                </ion-grid>\n</ion-col>\n         <ion-col col-md-9 col-12 *ngIf=\"left_side.comp_type === 'data_grid' && left_side.data_type === 'color_only'\"\n          class=\"pkg-detail-col\">\n\n               <ion-row class=\"pkg-hdr\">\n                    <div>Package Details</div>\n                 <!--   <button ion-button class=\"incom-btn\" (click)=\"incompletePkg()\"> Incomplete </button>-->\n                </ion-row>\n\n                <ion-row class=tol-qty>\n                    <span>Total QTY</span><span class=\"count\"></span>\n                </ion-row>\n                <ion-grid class=\"data-grid\">\n                 <ion-row *ngFor=\"let colorItem of current_color_list\" >\n                <ion-col col-4>{{colorItem.name}}</ion-col>\n                <ion-col col-3> <ion-input type=\"number\" [(ngModel)]=\"pkg_grid_data[colorItem.name]\"></ion-input></ion-col>\n                </ion-row>\n                </ion-grid>\n</ion-col>\n              <!--====end pkg info ==========-->\n\n\n        <!-- pass fail btn ====-->\n        <ion-col col-md-3 col-12 class=\"pass-fail-btn-col pass-fail-tab\">\n\n            <ion-row *ngFor=\"let box of this.right_side.comp_data\">\n                <button ion-button [color]=\"box.color\"\n                        (click)=\"mainPassFailButtonsClicked(box.value)\">\n                    {{box.name}}\n                </button>\n            </ion-row>\n\n        </ion-col>\n\n\n        <!-- pass fail btn mobile ====-->\n        <ion-row col-md-3 col-12 class=\"pass-fail-btn-col pass-fail-m\">\n\n            <ion-col *ngFor=\"let box of this.right_side.comp_data\">\n                <button ion-button [color]=\"box.color\"\n                        (click)=\"mainPassFailButtonsClicked(box.value)\">\n                    {{box.name}}\n                </button>\n            </ion-col>\n\n        </ion-row>\n\n\n        <!-- end pass fail btn\n        ======================-->\n        </ion-row>\n        <ion-row class=\"button-wraper\">\n            <ion-col class=\"bottom-card\"><span>Line</span><span class=\"valu-txt\"> {{current_line}}</span></ion-col>\n            <ion-col class=\"bottom-card\"><span>Cartoon Pass</span> <span class=\"valu-txt\">3/10</span></ion-col>\n            <ion-col class=\"bottom-card\"><span>Qty Pass</span> <span class=\"valu-txt\">7/10</span></ion-col>\n        </ion-row>\n\n        </ion-grid>\n\n    </ion-row>\n\n\n    </ion-grid>\n\n</ion-content>\n\n\n";
//# sourceMappingURL=aql-pkg-detail-template.js.map

/***/ }),

/***/ 1469:
/***/ (function(module, __webpack_exports__, __webpack_require__) {

"use strict";
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "a", function() { return AqlEvent; });
/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "b", function() { return AqlPkgItem; });
/**
 * Created by Paramee Gunethilake on 6/27/2018.
 */
var AqlEvent = /** @class */ (function () {
    function AqlEvent(obj) {
        this.ty = obj && obj.ty;
        this.nm = obj && obj.nm;
        this.vl = obj && obj.vl;
        this.cv = obj && obj.cv;
        this.ac = {};
        this.setACvalues(obj);
    }
    AqlEvent.prototype.setACvalues = function (obj) {
        this.ac['package_items'] = obj && obj.package_items;
        this.ac['status'] = obj && obj.status;
        this.ac['total_qty'] = obj && obj.total_qty;
        this.ac['shift'] = obj && obj.shift;
        this.ac['line'] = obj && obj.line;
        this.ac['package_issue'] = obj && obj.package_issue;
    };
    return AqlEvent;
}());

var AqlPkgItem = /** @class */ (function () {
    function AqlPkgItem(obj) {
        this.color = obj && obj.color;
        this.size = obj && obj.size || '';
        this.qty = obj && obj.qty;
        this.is_fail = obj && obj.is_fail;
        this.item_issue = obj && obj.item_issue;
    }
    return AqlPkgItem;
}());

//# sourceMappingURL=aql.event.js.map

/***/ })

});
//# sourceMappingURL=4.js.map