Example #1
0
<?php

use yii\helpers\Html;
use kartik\widgets\ActiveForm;
use kartik\widgets\DatePicker;
use yii\helpers\ArrayHelper;
use kartik\widgets\Select2;
use lukisongroup\master\models\Nmperusahaan;
$addressCorp = ArrayHelper::map(Nmperusahaan::find()->orderBy('NM_ALAMAT')->all(), 'ID', 'NM_ALAMAT');
?>

	<?php 
$form = ActiveForm::begin(['id' => 'frm-bil-proccess', 'enableClientValidation' => true, 'enableAjaxValidation' => true, 'method' => 'post', 'action' => ['/purchasing/purchase-order/billing-save']]);
?>
	
		<?php 
//echo  $form->field($poHeaderVal, 'bILLING')->textInput()->label('Billing');
echo $form->field($poHeaderVal, 'bILLING')->widget(Select2::classname(), ['data' => $addressCorp, 'options' => ['placeholder' => 'Select Address for Billing ...'], 'pluginOptions' => ['allowClear' => true]]);
?>
		<?php 
echo $form->field($poHeaderVal, 'kD_PO')->hiddenInput(['value' => $poHeader->KD_PO, 'maxlength' => true, 'readonly' => true])->label(false);
?>
		
		<div style="text-align: right;"">
			<?php 
echo Html::submitButton('simpan', ['class' => 'btn btn-primary']);
?>
		</div>
    
	<?php 
ActiveForm::end();
Example #2
0
use lukisongroup\master\models\Nmperusahaan;
use lukisongroup\purchasing\models\Purchasedetail;
use lukisongroup\esm\models\Barang;
/* @var $this yii\web\View */
/* @var $poHeader lukisongroup\poHeaders\esm\po\Purchaseorder */
$this->title = 'Detail PO';
$this->params['breadcrumbs'][] = ['label' => 'Purchaseorders', 'url' => ['index']];
$this->params['breadcrumbs'][] = $this->title;
$y = 4;
?>

 <?php 
$sup = Suplier::find()->where(['KD_SUPPLIER' => $poHeader->KD_SUPPLIER])->one();
//$pod = Purchasedetail::find()->where(['KD_PO'=>$poHeader->KD_PO])->all();
$ship = Nmperusahaan::find()->where(['ID' => $poHeader->SHIPPING])->one();
$bill = Nmperusahaan::find()->where(['ID' => $poHeader->BILLING])->one();
/* $x=10;
		function ax(){
			return '10';
		}
		 */
/* function formulaAmount($summary, $data, $widget){
				//$calculate = dataCell($model, $key, $index);
				//$p = compact('model', 'key', 'index');
				return '<div>'.$summary * $this->model().',</div>
						<div>'.min($data).'</div>
						<div>'.$summary.'</div>
						<div>100,0</div>
						<div><b>10000,0</b></div>'; 
		}; */
/*
Example #3
0
" onchange="hrga()" onkeypress="hrga()" onkeyup="hrga()"/>
				</td>
			</tr>

			<tr>
				<td style="text-align:right; font-size:13pt; font-weight:bold;">Total</td>
				<td>
					<input type="text" name="ttlHrgPjk" id="ttlHrgPjk" value="" disabled />
				</td>
			</tr>

		</tbody>
	</table>	

	<?php 
$nmpr = Nmperusahaan::find()->all();
?>
<div class="row form-horizontal">
  <div class="col-xs-12 col-sm-12 col-md-12">
	  <div class="form-group">
	    <label for="inputEmail3" class="col-sm-2 control-label">Shipping Address</label>
	    <div class="col-sm-5">
			<select class="form-control" name="shipping" required>
					<option value=""> -- PILIH --</option>
				<?php 
foreach ($nmpr as $nm) {
    ?>
					<option value="<?php 
    echo $nm->ID;
    ?>
" <?php 
Example #4
0
			
            <tr>
                <td style="text-align:right; background-color:#f2f2f2; border:1px solid #B2B2B2;"><b>Grand Total</b></td>
                <td style="border:1px solid #B2B2B2; background-color:#f2f2f2;"><b><?php 
echo Yii::$app->mastercode->Rupiah($hsl);
?>
</b></td>
            </tr>

        </tbody>
    </table>

    <br/><br/>
    <?php 
$ship = Nmperusahaan::find()->where(['ID' => $model->SHIPPING])->one();
$bill = Nmperusahaan::find()->where(['ID' => $model->BILLING])->one();
?>
        <table style="padding: 5px; ">
            <tr>
                <td>
                    <h3><u>Shipping Address :</u></h3>
                    <?php 
echo '<b>' . $ship->NM_ALAMAT . '</b>';
?>
<br/>
                    <?php 
echo $ship->ALAMAT_LENGKAP;
?>
<br/><br/>
                    <?php 
echo 'Tlp : ' . $ship->TLP;
Example #5
0
 public function getShip()
 {
     return $this->hasOne(Nmperusahaan::className(), ['ID' => 'SHIPPING']);
 }