master module 2 vadivel J 31-12-2024

This commit is contained in:
vadivelJ96 2024-12-31 11:47:26 +05:30
parent b9ac3c7df8
commit e31025bb37
3 changed files with 27 additions and 3 deletions

View File

@ -454,13 +454,13 @@ class Supplier extends BaseController
$addarr = [ 'name' => $name, 'created_by' => $userId, ];
if ($this->supplier_model->saveTransporter($addarr) > 0) {
$data = ['status' => true, 'message' => 'Successfully created transporter details'];
$data = ['status' => true, 'message' => "Successfully created $name transporter details"];
}
}else{
$editarr = ['name' => $name,'updated_by' => $userId];
if ($this->supplier_model->updateTransporter($editarr, $id) > 0) {
$data = ['status' => true,'message' => 'Successfully updated transporter details'];
$data = ['status' => true,'message' => "Successfully updated transporter details as $name "];
}
}

View File

@ -46,13 +46,15 @@
<form role="form" id="addconfig" action="<?php echo base_url() ?>configurationctrl/saveconfig" method="post">
<div class="form-row" style="margin-top:10px">
<div class=" col-md-3">
<label class="col-form-label" for="ConfigurationName">Configuration Name</label><span class="text-danger">*</span>
<label class="col-form-label" for="ConfigurationName">Configuration Name</label>
<font color="Red">*</font>
<?php
$data = array('name' => 'configurationname', 'value' => set_value('configurationname'), 'id' => 'configurationname', 'class' => 'form-control', 'required' => 'true', 'maxlength' => '20');
echo form_input($data); ?>
</div>
<div class=" col-md-3">
<label class="col-form-label" for="Comments">Comments</label>
<font color="Red">*</font>
<?php
$data = array('name' => 'Comments', 'value' => set_value('Comments'), 'id' => 'Comments', 'class' => 'form-control', 'required' => 'true', 'maxlength' => '20');
echo form_input($data);
@ -390,11 +392,19 @@
<script>
$('#addConFigBtnId').click(function (){
if($('#configurationname').val().trim() == ''){
alert('Please enter Configuration Name..!!');
return;
}
if($('#Comments').val().trim() == ''){
alert('Please enter comments..!!');
return;
}
$('#loader').show();
$.ajax({

View File

@ -495,6 +495,20 @@ if (!empty($master)) {
<script>
$('#updateConfigBtnId').click(function() {
if($('#ConfigName').val().trim() == ''){
alert('Please enter Configuration Name..!!');
return;
}
if($('#Remarks').val().trim() == ''){
alert('Please enter comments..!!');
return;
}
$('#loader').show();
$.ajax({
data: {