Subversion Repositories SmartDukaan

Rev

Rev 19918 | Blame | Compare with Previous | Last modification | View Log | RSS feed

<script>

$(document).ready(function(){
        if($('#MasterDataCategoryId').val() == "6")
        {
                $('#MasterDataInternalRank').prop('readonly',false);
        }
//      if($('#MasterDataSourceId').val() == "4"){
//              $("#MasterDataExclusive").removeAttr("disabled");
//      }
});
</script>

<div class="container">
        <div class="row">
                <div class="col-lg-3">
                        <?php echo $this->Element('adminactions');?>
                </div>
                <div class="col-lg-9">
                        <?php echo $this->Form->create('MasterData'); ?>
                                <fieldset>
                                        <legend><?php echo __('Add to existing Master Data bundle'); ?></legend>
                                <?php
                                        echo $this->Form->input('_id',array('readonly'=>true,'value'=>$data['_id'],'type'=>'text'));
                                        echo $this->Form->input('skuBundleId',array('readonly'=>true,'value'=>$data['skuBundleId']));
                                        echo $this->Form->input('available_price',array('value'=>$data['available_price']));
                                        echo $this->Form->input('gross_price',array('value'=>$data['gross_price']));
                                        echo $this->Form->input('brand',array('value'=>$data['brand']));
                                        echo $this->Form->input('cashback', array('type' => 'hidden','value'=>$data['cashback'] ));
                                        echo $this->Form->input('category_id',array('value'=>$data['category_id']));
                                        echo $this->Form->input('category',array('type'=>'text','value'=>$data['category']));
                                        echo $this->Form->input('identifier',array('required'=>1,'value'=>$data['identifier']));                                        
                                        echo $this->Form->input('marketPlaceUrl',array('value'=>$data['marketPlaceUrl']));
                                        echo $this->Form->input('model_name',array('value'=>$data['model_name']));
                                        echo $this->Form->input('mrp',array('value'=>$data['mrp']));

                                        $showmrp=array(0=>"False",1=>"True");
                                echo $this->Form->input('showMrp', array('options'=>$showmrp, 'selected'=>$data['showMrp']));

                                        echo $this->Form->input('maxPrice',array('value'=>$data['maxPrice']));
                                        echo $this->Form->input('product_name',array('value'=>$data['product_name']));
                                        echo $this->Form->input('rank',array('value'=>$data['rank']));          
                                        
                                        echo $this->Form->input('internalRank', array('type'=>'number','value'=> $data['internalRank'],'required'=> true,'readonly'=> true));
                                        echo $this->Form->input('source_id',array('value'=>$data['source_id']));
                                        echo $this->Form->input('source',array('type'=>'text','value'=>$data['source']));
                                        
//                                      echo $this->Form->label('Exclusive');
//                                      echo $this->Form->checkbox('exclusive',array('disabled' => true ,array('checked'=>$data['exclusive'])));
                                                
                                        echo $this->Form->input('secondaryIdentifier',array('value'=>$data['secondaryIdentifier']));
                                        echo $this->Form->input('sourceCategoryId', array('type' => 'hidden' ,'value'=>$data['sourceCategoryId']));
                                        echo $this->Form->input('sourceProductId', array('type' => 'hidden' ,'value'=>$data['sourceProductId']));                               
                                        echo $this->Form->input('source_product_name',array('value'=>$data['source_product_name']));
                                        echo $this->Form->input('source_url',array('value'=>$data['source_url']));
                                        echo $this->Form->input('status',array('value'=>$data['status']));
                                        echo $this->Form->input('in_stock',array('type'=>'select','options'=>$stock_statuses,'default'=>$data['in_stock']));                                    
                                        echo $this->Form->input('stock_status',array('type'=>'text','value'=>$data['stock_status']));
                                        echo $this->Form->input('thumbnail',array('value'=>$data['thumbnail']));
                                        echo $this->Form->input('url',array('value'=>$data['url']));

                                        echo $this->Form->input('quantity',array('type'=>'number','value'=>$data['quantity']));
                                        echo $this->Form->input('shippingCost',array('value'=>$data['shippingCost']));

                                        echo $this->Form->input('videoLink',array('value'=>$data['videoLink']));
                                        $arrCategory=array(0=>"False",1=>"True");
                                echo $this->Form->input('showVideo', array('options'=>$arrCategory, 'selected'=>$data['showVideo']));


//                              $arrSubCategory=array(0=>'None',7=>'Memory Card',8=>'Data Cable',9=>'USB Light',10=>'Screen Magnifier',11=>'Car Charger',12=>'Power Bank',13=>'Pendrive',14=>'Combo',15=>'Charger',16=>'Bluetooth Headset',17=>'Speaker',18=>'Adapter',20=>'Screen Guard',21=>'Earphone',22=>'Card Reader',23=>'Mobile Holder',24=>'Aux Cable',25=>'OTG Cable',26=>'Self Stick',27=>'Back Cover',28=>'Tempered Glass',29=>'Battery',30=>'Usb Hub',31=>'Portable Music Player');

                                
                                echo $this->Form->input('subCategoryId', array('options'=>$arrSubCategory, 'selected'=>$data['subCategoryId']));
                                echo $this->Form->label('Show Net Price');
                                echo $this->Form->checkbox('showNetPrice',array('checked'=>$data['showNetPrice']));
                                
                                
                                        echo $this->Form->input('offer',array('value'=>$data['offer'],'type'=>'textarea'));
                                        echo $this->Form->input('tagline',array('value'=>$data['tagline'],'type'=>'textarea'));
                                        echo $this->Form->input('is_shortage',array('type'=>'select','options'=>$shortage_status,'default'=>$data['is_shortage']));
                                        echo $this->Form->input('buyBoxFlag',array('type'=>'select','options'=>$buyBoxFlag,'default'=>$data['buyBoxFlag']));
                                        echo $this->Form->input('coupon',array('value'=>$data['coupon']));
                                        echo $this->Form->input('codAvailable',array('type'=>'select','options'=>$buyBoxFlag,'default'=>$data['codAvailable']));
                                        echo $this->Form->input('ignorePricing',array('type'=>'select','options'=>$buyBoxFlag,'default'=>$data['ignorePricing']));
                                        echo $this->Form->input('snapdealSpecialItem',array('type'=>'select','options'=>$buyBoxFlag,'default'=>$data['snapdealSpecialItem']));
                                        echo $this->Form->input('multi',array('type'=>'checkbox'));
                                ?>
                                </fieldset>
                        <?php echo $this->Form->end(__('Submit')); ?>
                        </div>
                </div>
        </div>
</div>
<script src="//cdn.ckeditor.com/4.5.2/full/ckeditor.js"></script>
<script type="text/javascript">
        CKEDITOR.replace( 'MasterDataOffer' );
        CKEDITOR.replace( 'MasterDataTagline' );
</script>