update manage schedule
This commit is contained in:
@@ -30,6 +30,8 @@
|
||||
<input type="hidden" name="DA_THEM_HINH_ANH_MAU" value="{Yii::t("app", "DA_THEM_HINH_ANH_MAU")}">
|
||||
<input type="hidden" name="CO_LOI_XAY_RA_HAY_THU_LAI" value="{Yii::t("app", "CO_LOI_XAY_RA_HAY_THU_LAI")}">
|
||||
<input type="hidden" name="ENGINE_KHONG_HOAT_DONG" value="{Yii::t("app", "ENGINE_KHONG_HOAT_DONG")}">
|
||||
<input type="hidden" name="HAY_CHON_DOI_TUONG_DE_GAN_LICH_TRINH" value="{Yii::t("app", "HAY_CHON_DOI_TUONG_DE_GAN_LICH_TRINH")}">
|
||||
<input type="hidden" name="BAN_CO_CHAC_CHAN_MUON_XOA_LICH_TRINH_NAY_KHONG" value="{Yii::t("app", "BAN_CO_CHAC_CHAN_MUON_XOA_LICH_TRINH_NAY_KHONG")}">
|
||||
|
||||
<div id="blocking" class="fade modal" role="dialog" tabindex="-1">
|
||||
<div class="modal-dialog" style="top: 50%;margin-top: -45px;">
|
||||
|
||||
@@ -8,9 +8,9 @@
|
||||
.row{
|
||||
margin-bottom: 5px;
|
||||
}
|
||||
input{
|
||||
width: 100%;
|
||||
}
|
||||
{*input{
|
||||
width: 100%;
|
||||
}*}
|
||||
.table-striped > tbody > tr:nth-of-type(odd){
|
||||
background-color: rgb(210, 210, 210);
|
||||
}
|
||||
@@ -21,13 +21,21 @@
|
||||
.feature-img:hover .btn{
|
||||
visibility: visible !important;
|
||||
}
|
||||
.table > tbody > tr.delete-choose > td{
|
||||
background-color: red;
|
||||
color: #fff;
|
||||
.btn-schedule{
|
||||
visibility: hidden;
|
||||
}
|
||||
.select2-container {
|
||||
.schedule-item:hover .btn-schedule{
|
||||
visibility: visible !important;
|
||||
}
|
||||
.table > tbody > tr.delete-choose > td{
|
||||
background-color: #F7D3D2;
|
||||
}
|
||||
#filters-face .select2-container {
|
||||
width: 100% !important;
|
||||
}
|
||||
.pagination {
|
||||
margin: 0;
|
||||
}
|
||||
#form-add-staff .select2-container--default .select2-selection--single, .select2-selection .select2-selection--single{
|
||||
border-color: green;
|
||||
}
|
||||
@@ -43,10 +51,10 @@
|
||||
<input type="hidden" value="{Url::to(["/list-management/update-feature"])}" name="update_feature_url">
|
||||
<input type="hidden" value="{Url::to(["/api/get-total-feature"])}" name="get_total_feature_url">
|
||||
<div class="row">
|
||||
<div class="col-md-10" style="max-height: 850px;overflow-y: auto;">
|
||||
<div class="col-md-10" id="list-face" style="max-height: 850px;overflow-y: auto;">
|
||||
{GridView::widget([
|
||||
'dataProvider' => $dataProvider,
|
||||
'layout'=> \app\helpers\ListManagementGrid::getLayout(),
|
||||
'layout'=> \app\helpers\ListManagementGrid::layout(20),
|
||||
'tableOptions' => [
|
||||
'class' => 'table table-striped table-bordered',
|
||||
'style' => 'background:#fff;min-width:700px;'
|
||||
@@ -58,6 +66,12 @@
|
||||
'contentOptions' => ['class' => 'text-center'],
|
||||
'headerOptions' => ['class' => 'text-center']
|
||||
],
|
||||
[
|
||||
'contentOptions' => ['class' => 'text-center hidden checkbox-column'],
|
||||
'headerOptions' => ['style' => 'width:3%', 'class' => 'hidden checkbox-column'],
|
||||
'format' => "raw",
|
||||
'value' => \app\helpers\ListManagementGrid::check()
|
||||
],
|
||||
[
|
||||
'attribute' => 'type',
|
||||
'contentOptions' => ['class' => 'text-center'],
|
||||
@@ -84,10 +98,10 @@
|
||||
'value' => \app\helpers\ListManagementGrid::image()
|
||||
],
|
||||
[
|
||||
'attribute' => 'time',
|
||||
'contentOptions' => ['class' => 'text-center'],
|
||||
'label' => Yii::t("app", "LICH_TRINH"),
|
||||
'headerOptions' => ['class' => 'text-center'],
|
||||
'value' => \app\helpers\ListManagementGrid::time()
|
||||
'format' => "raw",
|
||||
'value' => \app\helpers\ListManagementGrid::schedule()
|
||||
],
|
||||
[
|
||||
'attribute' => 'telephone',
|
||||
@@ -158,6 +172,7 @@
|
||||
<br>
|
||||
<div class="text-center">
|
||||
<button class="btn btn-danger" onclick="batchDelete(this);" data-href="{Url::to(['/list-management/batch-delete'])}">{Yii::t("app", "XAC_NHAN_XOA")}</button>
|
||||
<button class="btn btn-success" onclick="scheduleForm(this);" data-href="{Url::to(['/list-management/schedule'])}">{Yii::t("app", "LICH_TRINH")}</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
<div class="row">
|
||||
<div class="row" id="filters-face">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<div class="input-group">
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
<div class="row">
|
||||
<div class="row" id="filters-face">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<div class="input-group">
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
<div class="row">
|
||||
<div class="row" id="filters-face">
|
||||
<div class="col-md-4">
|
||||
<div class="form-group">
|
||||
<div class="input-group">
|
||||
|
||||
71
views/list-management/schedule-delete.tpl
Normal file
71
views/list-management/schedule-delete.tpl
Normal file
@@ -0,0 +1,71 @@
|
||||
<div class="row">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<label class="control-label">{Yii::t("app", "THOI_GIAN_VAO")}</label>
|
||||
<input type="text" value="{$model->from_time|default:"00:00"}" class="form-control" id="fromTime" disabled="" name="FromTime">
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<label class="control-label">{Yii::t("app", "THOI_GIAN_RA")}</label>
|
||||
<input type="text" value="{$model->to_time|default:"23:59"}" class="form-control" id="toTime" disabled=" name="ToTime">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<label class="control-label">{Yii::t("app", "NGAY_BAT_DAU")}</label>
|
||||
<input type="text" value="{$model->from_date|default:date("d/m/Y")}" class="form-control" disabled=" id="fromDate" name="FromDate">
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<label class="control-label">{Yii::t("app", "NGAY_KET_THUC")}</label>
|
||||
<input type="text" value="{$model->to_date|default:date("d/m/Y")}" class="form-control" disabled=" id="toDate" name="ToDate">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-12">
|
||||
<div class="form-group">
|
||||
<label class="control-label">{Yii::t("app", "NGAY_TRONG_TUAN")}</label>
|
||||
{$dateOfWeek=["1","2","3","4","5","6","7","8"]}
|
||||
{$dateOfWeek=explode(",",$model->date_of_week)}
|
||||
<div class="row">
|
||||
<div class="col-md-3">
|
||||
{if in_array("2",$dateOfWeek)}<i class="fa fa-check text-green"></i>{else}<i class="fa fa-remove text-red"></i>{/if} {Yii::t("app", "THU_HAI")}
|
||||
</div>
|
||||
<div class="col-md-3">
|
||||
{if in_array("3",$dateOfWeek)}<i class="fa fa-check text-green"></i>{else}<i class="fa fa-remove text-red"></i>{/if} {Yii::t("app", "THU_BA")}
|
||||
</div>
|
||||
<div class="col-md-3">
|
||||
{if in_array("4",$dateOfWeek)}<i class="fa fa-check text-green"></i>{else}<i class="fa fa-remove text-red"></i>{/if} {Yii::t("app", "THU_TU")}
|
||||
</div>
|
||||
<div class="col-md-3">
|
||||
{if in_array("5",$dateOfWeek)}<i class="fa fa-check text-green"></i>{else}<i class="fa fa-remove text-red"></i>{/if} {Yii::t("app", "THU_NAM")}
|
||||
</div>
|
||||
<div class="col-md-3">
|
||||
{if in_array("6",$dateOfWeek)}<i class="fa fa-check text-green"></i>{else}<i class="fa fa-remove text-red"></i>{/if} {Yii::t("app", "THU_SAU")}
|
||||
</div>
|
||||
<div class="col-md-3">
|
||||
{if in_array("7",$dateOfWeek)}<i class="fa fa-check text-green"></i>{else}<i class="fa fa-remove text-red"></i>{/if} {Yii::t("app", "THU_BAY")}
|
||||
</div>
|
||||
<div class="col-md-3">
|
||||
{if in_array("8",$dateOfWeek)}<i class="fa fa-check text-green"></i>{else}<i class="fa fa-remove text-red"></i>{/if} {Yii::t("app", "CHU_NHAT")}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-6">
|
||||
<input type='checkbox' value='1' name='editAll' checked=""> {Yii::t("app","AP_DUNG_CHO_TAT_CA_DOI_TUONG_DA_CHON")}
|
||||
</div>
|
||||
<div class="col-md-6 text-right">
|
||||
<button class="btn btn-danger" onclick="deleteSchedule(this);" data-href="{yii\helpers\Url::to(["/list-management/delete-schedule","id"=>$model->id])}">
|
||||
<i class="fa fa-remove"></i> {Yii::t("app","XOA_LICH_TRINH")}
|
||||
</button>
|
||||
<button type="button" class="btn btn-default" data-dismiss="modal"><span class="fa fa-remove"></span> {Yii::t("app", "DONG_LAI")}</button>
|
||||
</div>
|
||||
</div>
|
||||
80
views/list-management/schedule.tpl
Normal file
80
views/list-management/schedule.tpl
Normal file
@@ -0,0 +1,80 @@
|
||||
<div class="row">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<label class="control-label">{Yii::t("app", "THOI_GIAN_VAO")}</label>
|
||||
<input type="text" value="{$model->from_time|default:"00:00"}" class="form-control" id="fromTime" name="FromTime">
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<label class="control-label">{Yii::t("app", "THOI_GIAN_RA")}</label>
|
||||
<input type="text" value="{$model->to_time|default:"23:59"}" class="form-control" id="toTime" name="ToTime">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<label class="control-label">{Yii::t("app", "NGAY_BAT_DAU")}</label>
|
||||
<input type="text" value="{$model->from_date|default:date("d/m/Y")}" class="form-control" id="fromDate" name="FromDate">
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<div class="form-group">
|
||||
<label class="control-label">{Yii::t("app", "NGAY_KET_THUC")}</label>
|
||||
<input type="text" value="{$model->to_date|default:date("d/m/Y")}" class="form-control" id="toDate" name="ToDate">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-12">
|
||||
<div class="form-group">
|
||||
<label class="control-label">{Yii::t("app", "NGAY_TRONG_TUAN")}</label>
|
||||
{$dateOfWeek=["1","2","3","4","5","6","7","8"]}
|
||||
{if $type=="edit"}
|
||||
{$dateOfWeek=explode(",",$model->date_of_week)}
|
||||
{/if}
|
||||
<div class="row">
|
||||
<div class="col-md-3">
|
||||
<input type='checkbox' value='2' name="checkbox-date" {if in_array("2",$dateOfWeek)}checked=""{/if}> {Yii::t("app", "THU_HAI")}
|
||||
</div>
|
||||
<div class="col-md-3">
|
||||
<input type='checkbox' value='3' name="checkbox-date" {if in_array("3",$dateOfWeek)}checked=""{/if}> {Yii::t("app", "THU_BA")}
|
||||
</div>
|
||||
<div class="col-md-3">
|
||||
<input type='checkbox' value='4' name="checkbox-date" {if in_array("4",$dateOfWeek)}checked=""{/if}> {Yii::t("app", "THU_TU")}
|
||||
</div>
|
||||
<div class="col-md-3">
|
||||
<input type='checkbox' value='5' name="checkbox-date" {if in_array("5",$dateOfWeek)}checked=""{/if}> {Yii::t("app", "THU_NAM")}
|
||||
</div>
|
||||
<div class="col-md-3">
|
||||
<input type='checkbox' value='6' name="checkbox-date" {if in_array("6",$dateOfWeek)}checked=""{/if}> {Yii::t("app", "THU_SAU")}
|
||||
</div>
|
||||
<div class="col-md-3">
|
||||
<input type='checkbox' value='7' name="checkbox-date" {if in_array("7",$dateOfWeek)}checked=""{/if}> {Yii::t("app", "THU_BAY")}
|
||||
</div>
|
||||
<div class="col-md-3">
|
||||
<input type='checkbox' value='8' name="checkbox-date" {if in_array("8",$dateOfWeek)}checked=""{/if}> {Yii::t("app", "CHU_NHAT")}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-6">
|
||||
{if $type=="edit"}
|
||||
<input type='checkbox' value='1' name='editAll' checked=""> {Yii::t("app","AP_DUNG_CHO_TAT_CA_DOI_TUONG_DA_CHON")}
|
||||
{/if}
|
||||
</div>
|
||||
<div class="col-md-6 text-right">
|
||||
{if $type=="edit"}
|
||||
<button class="btn btn-primary" onclick="editSchedule(this);" data-href="{yii\helpers\Url::to(["/list-management/edit-schedule",'id'=>$model->id])}">
|
||||
<i class="fa fa-floppy-o"></i> {Yii::t("app","LUU_LAI")}
|
||||
</button>
|
||||
{else}
|
||||
<button class="btn btn-primary" onclick="addSchedule(this);" data-href="{yii\helpers\Url::to(["/list-management/schedule"])}">
|
||||
<i class="fa fa-floppy-o"></i> {Yii::t("app","LUU_LAI")}
|
||||
</button>
|
||||
{/if}
|
||||
</div>
|
||||
</div>
|
||||
Reference in New Issue
Block a user