files
This commit is contained in:
parent
0534828956
commit
0b6c2eea19
@ -529,12 +529,14 @@ $prefile =array();
|
|||||||
if($index == 1){
|
if($index == 1){
|
||||||
$filename = $value;
|
$filename = $value;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if(!empty($filename))
|
||||||
|
{
|
||||||
|
|
||||||
$myfile = array('FilePath'=>$filename,'PONO'=>$PONO);
|
$myfile = array('FilePath'=>$filename,'PONO'=>$PONO);
|
||||||
$this->purchaseorder_model->fileupload($myfile);
|
$this->purchaseorder_model->fileupload($myfile);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@ -4190,9 +4190,12 @@ $fcount = 0;
|
|||||||
|
|
||||||
if($fcount == 0)
|
if($fcount == 0)
|
||||||
{
|
{
|
||||||
$Picture = $this->adfile();
|
|
||||||
$filelist =array('PONO'=>$pono,'IGRNO'=>$igr,'FilePath'=>$Picture);
|
if(!empty($new_file_name))
|
||||||
$uploadfiles = $this->purchaseorder_model->insertfile($filelist);
|
{ $Picture = $this->adfile();
|
||||||
|
$filelist =array('PONO'=>$pono,'IGRNO'=>$igr,'FilePath'=>$Picture);
|
||||||
|
$uploadfiles = $this->purchaseorder_model->insertfile($filelist);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if($uploadfiles > 0){
|
if($uploadfiles > 0){
|
||||||
@ -4200,7 +4203,7 @@ $fcount = 0;
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
echo "File name already Exist";
|
echo " File name already Exist";
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@ -662,7 +662,6 @@ function uploadfile()
|
|||||||
|
|
||||||
$pono= $this->input->post('PONO');
|
$pono= $this->input->post('PONO');
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
$new_file_name =$_FILES['file']['name'];
|
$new_file_name =$_FILES['file']['name'];
|
||||||
|
|
||||||
@ -688,16 +687,22 @@ $upfile='';
|
|||||||
|
|
||||||
if($fcount == 0)
|
if($fcount == 0)
|
||||||
{
|
{
|
||||||
$Picture = $this->adfile();
|
|
||||||
|
if(!empty($new_file_name))
|
||||||
$filelist =array('PONO'=>$pono,'FilePath'=>$Picture);
|
{
|
||||||
$upfile = $this->purchaseorder_model->insertfile($filelist);
|
$Picture = $this->adfile();
|
||||||
|
$filelist =array('PONO'=>$pono,'FilePath'=>$Picture);
|
||||||
|
$upfile = $this->purchaseorder_model->insertfile($filelist);
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
if($upfile > 0){
|
if($upfile > 0){
|
||||||
echo "file updated successfully!";
|
echo "file updated successfully!";
|
||||||
}
|
}
|
||||||
else{
|
else{
|
||||||
echo "File name already Exist";
|
echo "File name already Exist";
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -3894,8 +3894,11 @@ function addRow()
|
|||||||
//alert();
|
//alert();
|
||||||
|
|
||||||
var file = $('#images').val();
|
var file = $('#images').val();
|
||||||
|
//alert(file);
|
||||||
|
// return false;
|
||||||
|
|
||||||
if (file=='')
|
if (file == '' || file == undefined)
|
||||||
|
|
||||||
{
|
{
|
||||||
alert('File not found');
|
alert('File not found');
|
||||||
|
|
||||||
|
|||||||
@ -5827,7 +5827,7 @@ else{
|
|||||||
//var file = $('#imag').val();
|
//var file = $('#imag').val();
|
||||||
|
|
||||||
var file = $('#images').val();
|
var file = $('#images').val();
|
||||||
if (file=='')
|
if (file == '' || file == undefined)
|
||||||
{
|
{
|
||||||
alert('File not found');
|
alert('File not found');
|
||||||
|
|
||||||
|
|||||||
@ -102,7 +102,7 @@ class CI_Upload {
|
|||||||
'image_size_str' => '',
|
'image_size_str' => '',
|
||||||
'error_msg' => array(),
|
'error_msg' => array(),
|
||||||
'mimes' => array(),
|
'mimes' => array(),
|
||||||
'remove_spaces' => TRUE,
|
'remove_spaces' => FALSE,
|
||||||
'xss_clean' => FALSE,
|
'xss_clean' => FALSE,
|
||||||
'temp_prefix' => "temp_file_",
|
'temp_prefix' => "temp_file_",
|
||||||
'client_name' => ''
|
'client_name' => ''
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user