예제 #1
4
 public function postCancelar()
 {
     //return Input::all();
     $this->response->Cancelar(Input::get('contratos'), Input::get('penaCapital'), Input::get('penaAccesorios'), Input::get('penaMoratorios'), Input::get('capital'));
     $cliente = DB::table('expediente')->where('id_expediente', Input::get('contratos'))->join('cliente', 'cliente.rfc', '=', 'expediente.fk_rfc')->select('cliente.nombre', 'cliente.ape_mate', 'cliente.ape_pate')->get()[0];
     $terreno = DB::table('expediente')->where('id_expediente', Input::get('contratos'))->join('solicitud', 'solicitud.fk_expediente', '=', 'expediente.id_expediente')->join('lote', 'lote.id_lote', '=', 'solicitud.fk_lote')->join('manzana', 'manzana.id_manzana', '=', 'lote.fk_manzana')->join('desarrollo', 'desarrollo.id_desarrollo', '=', 'manzana.fk_desarrollo')->select('lote.lote', 'manzana.num_letra', 'desarrollo.nombre')->get()[0];
     if (Input::get('capital') - Input::get('penaCapital') > 0) {
         $ImporteLiquido = Input::get('capital') - Input::get('penaCapital');
     } else {
         $ImporteLiquido = 0;
     }
     $PHPWord = new PHPWord();
     $document = $PHPWord->loadTemplate(dirname(__FILE__) . '/PHPWord/recibo_liquidacion.docx');
     $fecha = explode('-', date('Y-m-d'));
     $document->setValue('dia', $fecha[2]);
     $document->setValue('mes', $fecha[1]);
     $document->setValue('anio', $fecha[0]);
     $document->setValue('cantidadDevuelta', '$' . $ImporteLiquido);
     $document->setValue('expediente', Input::get('contratos'));
     $document->setValue('Terreno', $terreno->lote);
     $document->setValue('Manzana', $terreno->num_letra);
     $document->setValue('Fraccionamiento', $terreno->nombre);
     $document->setValue('Penalizacion', Input::get('penalizacionCapital') . '%');
     $document->setValue('PrecioVenta', '$' . Input::get('importeTotal'));
     $document->setValue('CapitalPagado', '$' . Input::get('capital'));
     $document->setValue('cantidadPenal', '$' . Input::get('penaCapital'));
     $document->setValue('ImporteLiquido', '$' . $ImporteLiquido);
     $document->setValue('Cliente', $cliente->nombre . " " . $cliente->ape_pate . " " . $cliente->ape_mate);
     $document->save(Input::get('contratos') . '_cancelacion.docx');
     return View::make('cobranza/mensajeCobranza')->with('datos', array('seccion' => 'SICyA | Cobranza | Cancealr Terreno', 'cabecera' => 'Cancelando Contrato', 'icono' => 'glyphicon glyphicon-file', 'tipo_mensaje' => true, 'mensaje' => "Se ha Cancelado el Contrato."));
 }
예제 #2
1
// Array Hari
$array_hari = array(1 => 'Senin', 'Selasa', 'Rabu', 'Kamis', 'Jumat', 'Sabtu', 'Minggu');
$hari = $array_hari[date('N')];
//Format Tanggal
$tanggal = date('j');
//Array Bulan
$array_bulan = array(1 => 'Januari', 'Februari', 'Maret', 'April', 'Mei', 'Juni', 'Juli', 'Agustus', 'September', 'Oktober', 'November', 'Desember');
$bulan = $array_bulan[date('n')];
//Format Tahun
$tahun = date('Y');
$bilangan = new Terbilang();
// Include the PHPWord.php, all other classes were loaded by an autoloader
include '../../../../../plugin/PHPWord.php';
// Create a new PHPWord Object
$PHPWord = new PHPWord();
$document = $PHPWord->loadTemplate('../../../../../config/Template/Amplop.docx');
$document->setValue('nama_pembeli', $nama_pembeli);
$document->setValue('alamat', $alamat);
$document->setValue('telepon', $tlp1);
$path = 'E:\\';
$nama_file = "AMPLOP PPJB " . $nama_pembeli . " " . $tanggal . " " . $bulan . " " . $tahun . ".doc";
// $document->save('E:\\andonnikahTemplate.docx');
//$document->save('E:\\'.$nama_file);
// At least write the document to webspace:
$objWriter = PHPWord_IOFactory::createWriter($PHPWord, 'Word2007');
// // save as a random file in temp file
$temp_file = tempnam(sys_get_temp_dir(), 'PHPWord');
$document->save($temp_file);
// Your browser will name the file "myFile.docx"
// regardless of what it's named on the server
header("Content-Disposition: attachment; filename=\"" . basename($nama_file) . "\"");
예제 #3
0
 /**
  * Executes index action
  *
  * @param sfRequest $request A request object
  */
 public function executeIndex(sfWebRequest $request)
 {
     // Recuperar el Tramite y el Proceso
     $this->setLayout('descarga');
     $template = Doctrine::getTable('ClaDocumentos')->findOneByClaTramiteIdAndClaProcesoId($request->getParameter('tramite'), $request->getParameter('proceso'));
     $seguimiento = Doctrine::getTable('ProcSeguimiento')->getTramite($request->getParameter('seguimiento'));
     $PHPWord = new PHPWord();
     $filename = 'carta_' . $request->getParameter('tramite') . '_' . $request->getParameter('proceso') . '.docx';
     $document = $PHPWord->loadTemplate(sfConfig::get('sf_root_dir') . '/archivos/templates/' . $template->getPath());
     date_default_timezone_set('America/La_Paz');
     setlocale(LC_TIME, 'spanish');
     $document->setValue('fecha_carta', strftime("%d de %B de %Y"));
     foreach ($seguimiento->ProcFormularios as $formulario) {
         $tabla = Doctrine::getTable($formulario->ClaTabla->getDescripcion())->findOneById($formulario->getGetId());
         if ($formulario->ClaTabla->getDescripcion() == 'DatPersonas') {
             $document->setValue('nombre_estudiante', $tabla->getNombreCompleto());
         }
     }
     $document->save(sfConfig::get('sf_root_dir') . '/archivos/generados/' . $filename);
     //        $guardar = new ClaDocumentos();
     //        $guardar->setClaTramiteId(1);
     //        $guardar->setClaProcesoId(1);
     //        $guardar->setPath($filename);
     //        $guardar->save();
     $this->filename = $filename;
     $this->enlace = sfConfig::get('sf_root_dir') . '/archivos/generados//' . $filename;
 }
 /**
  * create new excel document
  *
  * @return void
  */
 protected function _createDocument()
 {
     // this looks stupid, but the PHPDoc library is beta, so this is needed. otherwise the lib would create temp files in the template folder ;(
     $templateFile = $this->_getTemplateFilename();
     $tempTemplateFile = Tinebase_Core::guessTempDir() . DIRECTORY_SEPARATOR . Tinebase_Record_Abstract::generateUID() . '.docx';
     copy($templateFile, $tempTemplateFile);
     $this->_docObject = new PHPWord();
     if ($templateFile !== NULL) {
         $this->_docTemplate = $this->_docObject->loadTemplate($tempTemplateFile);
     }
     unlink($tempTemplateFile);
 }
 function createDoc($name = null)
 {
     $PHPWord = new PHPWord();
     //return;
     $this->getData();
     $template = $PHPWord->loadTemplate($this->modelliDir . $this->modello);
     foreach ($this->data as $tb => $data) {
         foreach ($data as $col => $val) {
             try {
                 $val = mb_detect_encoding($val) == 'UTF-8' ? utf8_decode($val) : $val;
                 $template->setValue("{$tb}.{$col}", $val);
             } catch (Exception $e) {
                 echo "<p>{$tb}.{$col}</p>";
             }
         }
     }
     $template->setValue("data", date("d/m/Y"));
     $pr = new pratica($this->pratica);
     $file = $name ? $pr->documenti . $name : $pr->documenti . $this->docName;
     $template->save($file);
 }
예제 #6
0
    public Function GeraArquivoDoc() {

	$PHPWord = new PHPWord();
	
	$arquivo_clinica = "../../../sgmo/laudo_modelo/$MY_PARAMETRO_ID/normal/$arquivo_laudo";

	$document = $PHPWord->loadTemplate($arquivo_clinica);

	//caso seja necessário preencher o cabeçalho com os dados da clínica
	$document->setValue('nome_emp', " $clinica_rs");
	$document->setValue('cnpj_emp', " $clinica_cnpj");
	$document->setValue('rua_emp', " $endereco");
	$document->setValue('tel_emp', " $tel_clinica");
	$document->setValue('cidade_emp', " $cidade");
	$document->setValue('estado_emp', " $estado");

	//Dados do funcinário para preencher o cabeçalho
	$document->setValue('nome_func', " $funcionario");
	$document->setValue('doc_func', " $doc_funcionario");
	$document->setValue('empresa_func', " $empresa");
	$document->setValue('dat_func', " $data_nascimento");
	$document->setValue('func_funcionario', " $funcao");
	$document->setValue('idade_func', " $idade");
	$document->setValue('tel_func', " $telefone");
	$document->setValue('idade_func', " $idade");
	$document->setValue('data_exame_func', " $data_exame");
	$document->setValue('medico_solicitante', " ");
	$document->setValue('medico_solicitante', " ");
	$document->setValue('convenio_func', " $clinica_rs");
	$document->setValue('observacao', " XXXXXXXXXXXXXXXXXXXXXX");

	//Marcações no documento
	$document->setValue('nx', "X");

	$nome_arquivo = $funcionario . "_" . $numero_ficha;
	$arquivo = "laudados/" . removerAcento($nome_arquivo) . ".docx";
	$document->save($arquivo);
    }
예제 #7
0
    function htmltoword()
    {
        import('@.ORG.PHPWord', '', $ext = '.php');
        $PHPWord = new PHPWord();
        $content = <<<code
\t<table cellspacing="0" cellpadding="0"><tbody><tr class="firstRow"><td width="95" valign="top" style="border: 1px solid windowtext; padding: 0px 7px;"><br></td><td width="95" valign="top" style="border-width: 1px 1px 1px medium; border-style: solid solid solid none; border-color: windowtext windowtext windowtext -moz-use-text-color; -moz-border-top-colors: none; -moz-border-right-colors: none; -moz-border-bottom-colors: none; -moz-border-left-colors: none; border-image: none; padding: 0px 7px;"><br></td><td width="95" valign="top" style="border-width: 1px 1px 1px medium; border-style: solid solid solid none; border-color: windowtext windowtext windowtext -moz-use-text-color; -moz-border-top-colors: none; -moz-border-right-colors: none; -moz-border-bottom-colors: none; -moz-border-left-colors: none; border-image: none; padding: 0px 7px;"><br></td><td width="95" valign="top" style="border-width: 1px 1px 1px medium; border-style: solid solid solid none; border-color: windowtext windowtext windowtext -moz-use-text-color; -moz-border-top-colors: none; -moz-border-right-colors: none; -moz-border-bottom-colors: none; -moz-border-left-colors: none; border-image: none; padding: 0px 7px;"><br></td><td width="95" valign="top" style="border-width: 1px 1px 1px medium; border-style: solid solid solid none; border-color: windowtext windowtext windowtext -moz-use-text-color; -moz-border-top-colors: none; -moz-border-right-colors: none; -moz-border-bottom-colors: none; -moz-border-left-colors: none; border-image: none; padding: 0px 7px;"><br></td><td width="95" valign="top" style="border-width: 1px 1px 1px medium; border-style: solid solid solid none; border-color: windowtext windowtext windowtext -moz-use-text-color; -moz-border-top-colors: none; -moz-border-right-colors: none; -moz-border-bottom-colors: none; -moz-border-left-colors: none; border-image: none; padding: 0px 7px;"><br></td></tr><tr><td width="95" valign="top" style="border-width: medium 1px 1px; border-style: none solid solid; border-color: -moz-use-text-color windowtext windowtext; -moz-border-top-colors: none; -moz-border-right-colors: none; -moz-border-bottom-colors: none; -moz-border-left-colors: none; border-image: none; padding: 0px 7px;"><br></td><td width="95" valign="top" style="border-width: medium 1px 1px medium; border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; padding: 0px 7px;"><br></td><td width="95" valign="top" style="border-width: medium 1px 1px medium; border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; padding: 0px 7px;" rowspan="3"><br></td><td width="95" valign="top" style="border-width: medium 1px 1px medium; border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; padding: 0px 7px;"><br></td><td width="95" valign="top" style="border-width: medium 1px 1px medium; border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; padding: 0px 7px;"><br></td><td width="95" valign="top" style="border-width: medium 1px 1px medium; border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; padding: 0px 7px;"><br></td></tr><tr><td width="95" valign="top" style="border-width: medium 1px 1px; border-style: none solid solid; border-color: -moz-use-text-color windowtext windowtext; -moz-border-top-colors: none; -moz-border-right-colors: none; -moz-border-bottom-colors: none; -moz-border-left-colors: none; border-image: none; padding: 0px 7px;"><br></td><td width="95" valign="top" style="border-width: medium 1px 1px medium; border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; padding: 0px 7px; word-break: break-all;">&#8203;<br></td><td width="95" valign="top" style="border-width: medium 1px 1px medium; border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; padding: 0px 7px;"><br></td><td width="95" valign="top" style="border-width: medium 1px 1px medium; border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; padding: 0px 7px;" rowspan="3"><br></td><td width="95" valign="top" style="border-width: medium 1px 1px medium; border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; padding: 0px 7px;"><br></td></tr><tr><td width="95" valign="top" style="border-width: medium 1px 1px; border-style: none solid solid; border-color: -moz-use-text-color windowtext windowtext; -moz-border-top-colors: none; -moz-border-right-colors: none; -moz-border-bottom-colors: none; -moz-border-left-colors: none; border-image: none; padding: 0px 7px;"><br></td><td width="95" valign="top" style="border-width: medium 1px 1px medium; border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; padding: 0px 7px;"><br></td><td width="95" valign="top" style="border-width: medium 1px 1px medium; border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; padding: 0px 7px;"><br></td><td width="95" valign="top" style="border-width: medium 1px 1px medium; border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; padding: 0px 7px;"><br></td></tr><tr><td width="95" valign="top" style="border-width: medium 1px 1px; border-style: none solid solid; border-color: -moz-use-text-color windowtext windowtext; -moz-border-top-colors: none; -moz-border-right-colors: none; -moz-border-bottom-colors: none; -moz-border-left-colors: none; border-image: none; padding: 0px 7px;"><br></td><td width="189" valign="top" style="border-width: medium 1px 1px medium; border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; padding: 0px 7px;" rowspan="2" colspan="2"><br></td><td width="95" valign="top" style="border-width: medium 1px 1px medium; border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; padding: 0px 7px;"><br></td><td width="95" valign="top" style="border-width: medium 1px 1px medium; border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; padding: 0px 7px;"><br></td></tr><tr><td width="95" valign="top" style="border-width: medium 1px 1px; border-style: none solid solid; border-color: -moz-use-text-color windowtext windowtext; -moz-border-top-colors: none; -moz-border-right-colors: none; -moz-border-bottom-colors: none; -moz-border-left-colors: none; border-image: none; padding: 0px 7px;"><br></td><td width="95" valign="top" style="border-width: medium 1px 1px medium; border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; padding: 0px 7px;"><br></td><td width="95" valign="top" style="border-width: medium 1px 1px medium; border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; padding: 0px 7px;"><br></td><td width="95" valign="top" style="border-width: medium 1px 1px medium; border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; padding: 0px 7px;"><br></td></tr><tr><td width="95" valign="top" style="border-width: medium 1px 1px; border-style: none solid solid; border-color: -moz-use-text-color windowtext windowtext; -moz-border-top-colors: none; -moz-border-right-colors: none; -moz-border-bottom-colors: none; -moz-border-left-colors: none; border-image: none; padding: 0px 7px;"><br></td><td width="95" valign="top" style="border-width: medium 1px 1px medium; border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; padding: 0px 7px;"><br></td><td width="95" valign="top" style="border-width: medium 1px 1px medium; border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; padding: 0px 7px;"><br></td><td width="95" valign="top" style="border-width: medium 1px 1px medium; border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; padding: 0px 7px;"><br></td><td width="95" valign="top" style="border-width: medium 1px 1px medium; border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; padding: 0px 7px;"><br></td><td width="95" valign="top" style="border-width: medium 1px 1px medium; border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; padding: 0px 7px;"><br></td></tr></tbody></table>
\t\t<table cellspacing="0" cellpadding="0"><tbody><tr class="firstRow"><td width="142" valign="top" style="border: 1px solid windowtext; padding: 0px 7px;" rowspan="3"><p class="edit-text">11111</p></td><td width="142" valign="top" style="border-width: 1px 1px 1px medium; border-style: solid solid solid none; border-color: windowtext windowtext windowtext -moz-use-text-color; -moz-border-top-colors: none; -moz-border-right-colors: none; -moz-border-bottom-colors: none; -moz-border-left-colors: none; border-image: none; padding: 0px 7px;"><br></td><td width="142" valign="top" style="border-width: 1px 1px 1px medium; border-style: solid solid solid none; border-color: windowtext windowtext windowtext -moz-use-text-color; -moz-border-top-colors: none; -moz-border-right-colors: none; -moz-border-bottom-colors: none; -moz-border-left-colors: none; border-image: none; padding: 0px 7px;"><br></td><td width="142" valign="top" style="border-width: 1px 1px 1px medium; border-style: solid solid solid none; border-color: windowtext windowtext windowtext -moz-use-text-color; -moz-border-top-colors: none; -moz-border-right-colors: none; -moz-border-bottom-colors: none; -moz-border-left-colors: none; border-image: none; padding: 0px 7px;"><br></td></tr><tr><td width="426" valign="top" style="border-width: medium 1px 1px medium; border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; padding: 0px 7px;" colspan="3"><p class="edit-text">444444</p></td></tr><tr><td width="142" valign="top" style="border-width: medium 1px 1px medium; border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; padding: 0px 7px;"><br></td><td width="142" valign="top" style="border-width: medium 1px 1px medium; border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; padding: 0px 7px;"><br></td><td width="142" valign="top" style="border-width: medium 1px 1px medium; border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; padding: 0px 7px;"><br></td></tr><tr><td width="142" valign="top" style="border-width: medium 1px 1px; border-style: none solid solid; border-color: -moz-use-text-color windowtext windowtext; -moz-border-top-colors: none; -moz-border-right-colors: none; -moz-border-bottom-colors: none; -moz-border-left-colors: none; border-image: none; padding: 0px 7px;"><br></td><td width="142" valign="top" style="border-width: medium 1px 1px medium; border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; padding: 0px 7px;"><br></td><td width="142" valign="top" style="border-width: medium 1px 1px medium; border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; padding: 0px 7px;"><br></td><td width="142" valign="top" style="border-width: medium 1px 1px medium; border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; padding: 0px 7px;"><br></td></tr><tr><td width="142" valign="top" style="border-width: medium 1px 1px; border-style: none solid solid; border-color: -moz-use-text-color windowtext windowtext; -moz-border-top-colors: none; -moz-border-right-colors: none; -moz-border-bottom-colors: none; -moz-border-left-colors: none; border-image: none; padding: 0px 7px;" rowspan="2"><p class="edit-text">22222</p></td><td width="426" valign="top" style="border-width: medium 1px 1px medium; border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; padding: 0px 7px;" colspan="3"><p class="edit-text">33333</p></td></tr><tr><td width="142" valign="top" style="border-width: medium 1px 1px medium; border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; padding: 0px 7px;"><br></td><td width="142" valign="top" style="border-width: medium 1px 1px medium; border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; padding: 0px 7px;"><br></td><td width="142" valign="top" style="border-width: medium 1px 1px medium; border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; padding: 0px 7px;"><br></td></tr><tr><td width="142" valign="top" style="border-width: medium 1px 1px; border-style: none solid solid; border-color: -moz-use-text-color windowtext windowtext; -moz-border-top-colors: none; -moz-border-right-colors: none; -moz-border-bottom-colors: none; -moz-border-left-colors: none; border-image: none; padding: 0px 7px;"><br></td><td width="142" valign="top" style="border-width: medium 1px 1px medium; border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; padding: 0px 7px;"><br></td><td width="142" valign="top" style="border-width: medium 1px 1px medium; border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; padding: 0px 7px;"><br></td><td width="142" valign="top" style="border-width: medium 1px 1px medium; border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; padding: 0px 7px;"><br></td></tr><tr><td width="142" valign="top" style="border-width: medium 1px 1px; border-style: none solid solid; border-color: -moz-use-text-color windowtext windowtext; -moz-border-top-colors: none; -moz-border-right-colors: none; -moz-border-bottom-colors: none; -moz-border-left-colors: none; border-image: none; padding: 0px 7px;"><br></td><td width="142" valign="top" style="border-width: medium 1px 1px medium; border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; padding: 0px 7px;"><br></td><td width="142" valign="top" style="border-width: medium 1px 1px medium; border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; padding: 0px 7px;"><br></td><td width="142" valign="top" style="border-width: medium 1px 1px medium; border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; padding: 0px 7px;"><br></td></tr></tbody></table>
code;
        $content = <<<code
<table width="100" cellspacing="0" cellpadding="0"><tbody><tr class="firstRow"><td width="2" style="border: 1px solid black; background: rgb(242, 242, 242) none repeat scroll 0% 0%; padding: 0px 7px;" rowspan="3"><p style="text-align:center"><strong><span style="font-family:宋体">接口名称</span></strong></p></td><td width="41" style="border-width: 1px 1px 1px medium; border-style: solid solid solid none; border-color: black black black -moz-use-text-color; -moz-border-top-colors: none; -moz-border-right-colors: none; -moz-border-bottom-colors: none; -moz-border-left-colors: none; border-image: none; background: rgb(242, 242, 242) none repeat scroll 0% 0%; padding: 0px 7px;" colspan="3"><p style="text-align:center"><strong><span style="font-family:宋体">源头数据库</span>(From)</strong></p></td><td width="45" style="border-width: 1px 1px 1px medium; border-style: solid solid solid none; border-color: black black black -moz-use-text-color; -moz-border-top-colors: none; -moz-border-right-colors: none; -moz-border-bottom-colors: none; -moz-border-left-colors: none; border-image: none; background: rgb(242, 242, 242) none repeat scroll 0% 0%; padding: 0px 7px;" colspan="3"><p style="text-align:center"><strong><span style="font-family:宋体">目标数据库</span>(To)</strong></p></td><td width="10" valign="top" style="border-width: 1px 1px 1px medium; border-style: solid solid solid none; border-color: black black black -moz-use-text-color; -moz-border-top-colors: none; -moz-border-right-colors: none; -moz-border-bottom-colors: none; -moz-border-left-colors: none; border-image: none; background: rgb(242, 242, 242) none repeat scroll 0% 0%; padding: 0px 7px;" rowspan="3"><p style="text-align:center"><strong><span style="font-family:宋体">说明</span></strong></p></td></tr><tr><td width="41" style="border-width: medium 1px 1px medium; border-style: none solid solid none; border-color: -moz-use-text-color black black -moz-use-text-color; background: rgb(242, 242, 242) none repeat scroll 0% 0%; padding: 0px 7px;" colspan="3"><p style="text-align:left"><strong><span style="font-family:宋体">地址:</span>192.168.0.237</strong></p><p style="text-align:left"><strong><span style="font-family:宋体">数据库:</span>nydbexec</strong></p><p style="text-align:left"><strong><span style="font-family:宋体">端口:</span></strong></p><p style="text-align:left"><strong><span style="font-family:宋体">账号:</span>root</strong></p><p style="text-align:left"><strong><span style="font-family:宋体">密码:</span>tml123456</strong></p></td><td width="45" style="border-width: medium 1px 1px medium; border-style: none solid solid none; border-color: -moz-use-text-color black black -moz-use-text-color; background: rgb(242, 242, 242) none repeat scroll 0% 0%; padding: 0px 7px;" colspan="3"><p style="text-align:left"><strong><span style="font-family:宋体">地址:</span>192.168.0.100</strong></p><p style="text-align:left"><strong><span style="font-family:宋体">数据库:</span>ufdata_101_2015</strong></p><p style="text-align:left"><strong><span style="font-family:宋体">端口:</span></strong></p><p style="text-align:left"><strong><span style="font-family:宋体">账号:</span>sa</strong></p><p style="text-align:left"><strong><span style="font-family:宋体">密码:</span></strong></p></td></tr><tr><td width="5" style="border-width: medium 1px 1px medium; border-style: none solid solid none; border-color: -moz-use-text-color black black -moz-use-text-color; background: rgb(242, 242, 242) none repeat scroll 0% 0%; padding: 0px 7px;"><p style="text-align:center"><strong><span style="font-family:宋体">数据库表</span></strong></p></td><td width="5" style="border-width: medium 1px 1px medium; border-style: none solid solid none; border-color: -moz-use-text-color black black -moz-use-text-color; background: rgb(242, 242, 242) none repeat scroll 0% 0%; padding: 0px 7px;"><p style="text-align:center"><strong><span style="font-family:宋体">属性</span></strong></p></td><td width="30" style="border-width: medium 1px 1px medium; border-style: none solid solid none; border-color: -moz-use-text-color black black -moz-use-text-color; background: rgb(242, 242, 242) none repeat scroll 0% 0%; padding: 0px 7px;"><p style="text-align:center"><strong><span style="font-family:宋体">其他</span></strong></p></td><td width="2" style="border-width: medium 1px 1px medium; border-style: none solid solid none; border-color: -moz-use-text-color black black -moz-use-text-color; background: rgb(242, 242, 242) none repeat scroll 0% 0%; padding: 0px 7px;"><p style="text-align:center"><strong><span style="font-family:宋体">数据库表</span></strong></p></td><td width="3" style="border-width: medium 1px 1px medium; border-style: none solid solid none; border-color: -moz-use-text-color black black -moz-use-text-color; background: rgb(242, 242, 242) none repeat scroll 0% 0%; padding: 0px 7px;"><p style="text-align:center"><strong><span style="font-family:宋体">属性</span></strong></p></td><td width="39" style="border-width: medium 1px 1px medium; border-style: none solid solid none; border-color: -moz-use-text-color black black -moz-use-text-color; background: rgb(242, 242, 242) none repeat scroll 0% 0%; padding: 0px 7px;"><p style="text-align:center"><strong><span style="font-family:宋体">其他</span></strong></p></td></tr><tr style=";height:120px"><td width="2" valign="top" height="120" style="border-width: medium 1px 1px; border-style: none solid solid; border-color: -moz-use-text-color black black; -moz-border-top-colors: none; -moz-border-right-colors: none; -moz-border-bottom-colors: none; -moz-border-left-colors: none; border-image: none; padding: 0px 7px;"><p><span style="font-family:   宋体">薪资接口:</span></p><p><span style="font-family:   宋体">按需同步</span> <span style="font-family:宋体">按年份</span>+<span style="font-family:宋体">月份同步</span> <span style="font-family:宋体">,</span>pmp<span style="font-family:宋体">存出过程会按年份</span>+<span style="font-family:宋体">月份删除即将同步数据</span></p></td><td width="5" valign="top" height="120" style="border-width: medium 1px 1px medium; border-style: none solid solid none; border-color: -moz-use-text-color black black -moz-use-text-color; padding: 0px 7px;"><p>U8<span style="font-family:宋体">数据源视图:</span> pmpgzview</p><p>&nbsp;</p></td><td width="5" valign="top" height="120" style="border-width: medium 1px 1px medium; border-style: none solid solid none; border-color: -moz-use-text-color black black -moz-use-text-color; padding: 0px 7px;"><p>gzlbinfo.cgzdlname &nbsp; as <span style="font-family:宋体">工资大类</span>,</p><p>WA_GZData.cgzgradenum &nbsp; as <span style="font-family:宋体">类别编码</span>,</p><p>gzlbinfo.cgzgradename &nbsp; as <span style="font-family:宋体">类别名称</span>,</p><p>WA_GZData.cpsn_num&nbsp;&nbsp; AS&nbsp;&nbsp;&nbsp;&nbsp; <span style="font-family:宋体">人员编码</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ,</p><p>hr_hi_person.cpsn_name &nbsp; as <span style="font-family:宋体">人员名称</span>,</p><p>WA_GZData.cDept_Num&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; AS&nbsp;&nbsp;&nbsp;&nbsp; <span style="font-family:宋体">部门编码</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ,</p><p>Department.cdepname &nbsp; as <span style="font-family:宋体">部门名称</span>,</p><p>WA_GZData.iPsnGrd_id&nbsp; AS&nbsp;&nbsp;&nbsp;&nbsp; iPsnGrd_id&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ,</p><p>WA_GZData.iYear&nbsp;&nbsp; AS&nbsp;&nbsp;&nbsp;&nbsp; <span style="font-family:宋体">年份</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ,</p><p>iMonth&nbsp;&nbsp;&nbsp;&nbsp; AS&nbsp;&nbsp;&nbsp;&nbsp; <span style="font-family:宋体">月份</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ,</p><p>iAccMonth&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; AS&nbsp;&nbsp;&nbsp;&nbsp; iAccMonth&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ,</p><p>F_1&nbsp;&nbsp; AS&nbsp;&nbsp;&nbsp;&nbsp; <span style="font-family:宋体">应发合计</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ,</p><p>F_2&nbsp;&nbsp; AS&nbsp;&nbsp;&nbsp;&nbsp; <span style="font-family:宋体">扣款合计</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ,</p><p>F_3&nbsp;&nbsp; AS&nbsp;&nbsp;&nbsp;&nbsp; <span style="font-family:宋体">实发合计</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ,</p><p>F_4&nbsp;&nbsp; AS&nbsp;&nbsp;&nbsp;&nbsp; <span style="font-family:宋体">本月扣零</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ,</p><p>F_5&nbsp;&nbsp; AS&nbsp;&nbsp;&nbsp;&nbsp; <span style="font-family:宋体">上月扣零</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ,</p><p>F_6&nbsp;&nbsp; AS&nbsp;&nbsp;&nbsp;&nbsp; <span style="font-family:宋体">代扣税</span>&nbsp;&nbsp;&nbsp;&nbsp; ,</p><p>F_7&nbsp;&nbsp; AS&nbsp;&nbsp;&nbsp;&nbsp; <span style="font-family:宋体">计件工资</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ,</p><p>WA_GZData.bLastFlag&nbsp;&nbsp;&nbsp; AS&nbsp;&nbsp;&nbsp;&nbsp; bLastFlag ,</p><p>WA_GZData.vStatus1&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; AS&nbsp;&nbsp;&nbsp;&nbsp; vStatus1&nbsp; ,</p><p>WA_GZData.nStatus2&nbsp;&nbsp;&nbsp;&nbsp; AS&nbsp;&nbsp;&nbsp;&nbsp; nStatus2&nbsp; ,</p><p>WA_GZData.iRecordID&nbsp;&nbsp; AS&nbsp;&nbsp;&nbsp;&nbsp; iRecordID&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ,</p><p>F_1000&nbsp;&nbsp;&nbsp;&nbsp; AS&nbsp;&nbsp;&nbsp;&nbsp; <span style="font-family:宋体">代付税</span>&nbsp;&nbsp;&nbsp;&nbsp; ,</p><p>F_1001&nbsp;&nbsp;&nbsp;&nbsp; AS&nbsp;&nbsp;&nbsp;&nbsp; <span style="font-family:宋体">年终奖</span>&nbsp;&nbsp;&nbsp;&nbsp; ,</p><p>F_1002&nbsp;&nbsp;&nbsp;&nbsp; AS&nbsp;&nbsp;&nbsp;&nbsp; <span style="font-family:宋体">年终奖代扣税</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ,</p><p>F_1003&nbsp;&nbsp;&nbsp;&nbsp; AS&nbsp;&nbsp;&nbsp;&nbsp; <span style="font-family:宋体">工资代扣税</span>&nbsp;&nbsp;&nbsp;&nbsp; ,</p><p>F_1004&nbsp;&nbsp;&nbsp;&nbsp; AS&nbsp;&nbsp;&nbsp;&nbsp; <span style="font-family:宋体">扣税合计</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ,</p><p>F_1005&nbsp;&nbsp;&nbsp;&nbsp; AS&nbsp;&nbsp;&nbsp;&nbsp; <span style="font-family:宋体">年终奖代付税</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ,</p><p>F_1006&nbsp;&nbsp;&nbsp;&nbsp; AS&nbsp;&nbsp;&nbsp;&nbsp; <span style="font-family:宋体">工资代付税</span>&nbsp;&nbsp;&nbsp;&nbsp; ,</p><p>F_8&nbsp;&nbsp; AS&nbsp;&nbsp;&nbsp;&nbsp; <span style="font-family:宋体">工资级别</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ,</p><p>F_9&nbsp;&nbsp; AS&nbsp;&nbsp;&nbsp;&nbsp; <span style="font-family:宋体">工资序列</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ,</p><p>F_10&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; AS&nbsp;&nbsp;&nbsp;&nbsp; <span style="font-family:宋体">工资等级</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ,</p><p>F_11&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; AS&nbsp;&nbsp;&nbsp;&nbsp; <span style="font-family:宋体">工资档次</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ,</p><p>F_12&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; AS&nbsp;&nbsp;&nbsp;&nbsp; <span style="font-family:宋体">年岗位技能工资</span>&nbsp;&nbsp;&nbsp;&nbsp; ,</p><p>F_13&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; AS&nbsp;&nbsp;&nbsp;&nbsp; <span style="font-family:宋体">月工资</span>&nbsp;&nbsp;&nbsp;&nbsp; ,</p><p>F_14&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; AS&nbsp;&nbsp;&nbsp;&nbsp; <span style="font-family:宋体">月基薪</span>&nbsp;&nbsp;&nbsp;&nbsp; ,</p><p>F_15&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; AS&nbsp;&nbsp;&nbsp;&nbsp; <span style="font-family:宋体">月绩效</span>&nbsp;&nbsp;&nbsp;&nbsp; ,</p><p>F_16&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; AS&nbsp;&nbsp;&nbsp;&nbsp; <span style="font-family:宋体">年功工资</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ,</p><p>F_17&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; AS&nbsp;&nbsp;&nbsp;&nbsp; <span style="font-family:宋体">加班工资</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ,</p><p>F_18&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; AS&nbsp;&nbsp;&nbsp;&nbsp; <span style="font-family:宋体">月预扣风险金</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ,</p><p>F_19&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; AS&nbsp;&nbsp;&nbsp;&nbsp; <span style="font-family:宋体">社保基数</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ,</p><p>F_20&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; AS&nbsp;&nbsp;&nbsp;&nbsp; <span style="font-family:宋体">公积金基数</span>&nbsp;&nbsp;&nbsp;&nbsp; ,</p><p>F_21&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; AS&nbsp;&nbsp;&nbsp;&nbsp; <span style="font-family:宋体">养老保险金</span>&nbsp;&nbsp;&nbsp;&nbsp; ,</p><p>F_22&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; AS&nbsp;&nbsp;&nbsp;&nbsp; <span style="font-family:宋体">医疗保险金</span>&nbsp;&nbsp;&nbsp;&nbsp; ,</p><p>F_23&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; AS&nbsp;&nbsp;&nbsp;&nbsp; <span style="font-family:宋体">失业保险金</span>&nbsp;&nbsp;&nbsp;&nbsp; ,</p><p>F_24&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; AS&nbsp;&nbsp;&nbsp;&nbsp; <span style="font-family:宋体">生育保险金</span>&nbsp;&nbsp;&nbsp;&nbsp; ,</p><p>F_25&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; AS&nbsp;&nbsp;&nbsp;&nbsp; <span style="font-family:宋体">住房公积金</span>&nbsp;&nbsp;&nbsp;&nbsp; ,</p><p>F_26&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; AS&nbsp;&nbsp;&nbsp;&nbsp; <span style="font-family:宋体">社保调整</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ,</p><p>F_27&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; AS&nbsp;&nbsp;&nbsp;&nbsp; <span style="font-family:宋体">计税金额</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ,</p><p>F_28&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; AS&nbsp;&nbsp;&nbsp;&nbsp; <span style="font-family:宋体">其他免税项目</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ,</p><p>F_29&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; AS&nbsp;&nbsp;&nbsp;&nbsp; <span style="font-family:宋体">应发小计</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ,</p><p>F_30&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; AS&nbsp;&nbsp;&nbsp;&nbsp; <span style="font-family:宋体">通讯费扣款</span>&nbsp;&nbsp;&nbsp;&nbsp; ,</p><p>F_31&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; AS&nbsp;&nbsp;&nbsp;&nbsp; <span style="font-family:宋体">五险一金扣款</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ,</p><p>F_32&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; AS&nbsp;&nbsp;&nbsp;&nbsp; <span style="font-family:宋体">病事缺扣款</span>&nbsp;&nbsp;&nbsp;&nbsp; ,</p><p>F_33&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; AS&nbsp;&nbsp;&nbsp;&nbsp; <span style="font-family:宋体">迟到扣款</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ,</p><p>F_34&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; AS&nbsp;&nbsp;&nbsp;&nbsp; <span style="font-family:宋体">上月校错</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ,</p><p>F_35&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; AS&nbsp;&nbsp;&nbsp;&nbsp; <span style="font-family:宋体">车贴</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ,</p><p>F_36&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; AS&nbsp;&nbsp;&nbsp;&nbsp; <span style="font-family:宋体">财务挂账</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ,</p><p>F_37&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; AS&nbsp;&nbsp;&nbsp;&nbsp; <span style="font-family:宋体">消财务挂账</span>&nbsp;&nbsp;&nbsp;&nbsp; ,</p><p>F_38&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; AS&nbsp;&nbsp;&nbsp;&nbsp; <span style="font-family:宋体">扣款小计</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ,</p><p>F_39&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; AS&nbsp;&nbsp;&nbsp;&nbsp; <span style="font-family:宋体">一次性绩效发放</span>&nbsp;&nbsp;&nbsp;&nbsp; ,</p><p>F_40&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; AS&nbsp;&nbsp;&nbsp;&nbsp; <span style="font-family:宋体">季度绩效补差</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ,</p><p>F_41&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; AS&nbsp;&nbsp;&nbsp;&nbsp; <span style="font-family:宋体">风险金调差</span>&nbsp;&nbsp;&nbsp;&nbsp; ,</p><p>F_42&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; AS&nbsp;&nbsp;&nbsp;&nbsp; <span style="font-family:宋体">本月实际计薪天数</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ,</p><p>F_43&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; AS&nbsp;&nbsp;&nbsp;&nbsp; <span style="font-family:宋体">返风险金</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ,</p><p>F_44&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; AS&nbsp;&nbsp;&nbsp;&nbsp; <span style="font-family:宋体">实习补助标准</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ,</p><p>F_45&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; AS&nbsp;&nbsp;&nbsp;&nbsp; <span style="font-family:宋体">本月出勤率</span>&nbsp;&nbsp;&nbsp;&nbsp; ,</p><p>F_46&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; AS&nbsp;&nbsp;&nbsp;&nbsp; <span style="font-family:宋体">绩效考勤等级</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ,</p><p>F_47&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; AS&nbsp;&nbsp;&nbsp;&nbsp; <span style="font-family:宋体">绩效摊销</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ,</p><p>F_48&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; AS&nbsp;&nbsp;&nbsp;&nbsp; <span style="font-family:宋体">创新先进个人奖励</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ,</p><p>F_49&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; AS&nbsp;&nbsp;&nbsp;&nbsp; <span style="font-family:宋体">缺勤天数</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ,</p><p>F_50&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; AS&nbsp;&nbsp;&nbsp;&nbsp; <span style="font-family:宋体">平时加班天数</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ,</p><p>F_51&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; AS&nbsp;&nbsp;&nbsp;&nbsp; <span style="font-family:宋体">迟到次数</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ,</p><p>F_52&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; AS&nbsp;&nbsp;&nbsp;&nbsp; <span style="font-family:宋体">周末加班天数</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ,</p><p>F_53&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; AS&nbsp;&nbsp;&nbsp;&nbsp; <span style="font-family:宋体">节假日加班天数</span></p></td><td width="30" valign="top" height="120" style="border-width: medium 1px 1px medium; border-style: none solid solid none; border-color: -moz-use-text-color black black -moz-use-text-color; padding: 0px 7px;"><p><span style="font-family:   宋体">调用实例:</span></p><p>CALL &nbsp; `pmpxzin` (&nbsp; -- pmp <span style="font-family:宋体">平台的数据接口</span></p><p>'001',&nbsp; -- <span style="font-family:宋体">工资大类</span></p><p>'001' &nbsp; , -- <span style="font-family:宋体">类别编码</span></p><p>'<span style="font-family:宋体">基本工资</span>' , -- <span style="font-family:   宋体">类别名称</span></p><p>'100001', &nbsp; -- <span style="font-family:宋体">人员编码</span></p><p>2 , -- &nbsp; <span style="font-family:宋体">部门编码</span></p><p>NULL , &nbsp; -- iPsnGrd_id</p><p>NULL , &nbsp; -- iPsnAmt</p><p>2015 , &nbsp; -- <span style="font-family:宋体">年份</span></p><p>8, -- <span style="font-family:宋体">月份</span></p><p>NULL , &nbsp; -- iAccMonth</p><p>3882.44 &nbsp; , --&nbsp; <span style="font-family:   宋体">应发合计</span> </p><p>283.838 &nbsp; , --&nbsp; <span style="font-family:   宋体">扣款合计</span> </p><p>4883.83 &nbsp; , --&nbsp; <span style="font-family:   宋体">实发合计</span> </p><p>789.38 &nbsp; , --&nbsp; <span style="font-family:   宋体">本月扣零</span> </p><p>483.83 &nbsp; , --&nbsp; <span style="font-family:   宋体">上月扣零</span> </p><p>38.83 &nbsp; , --&nbsp; <span style="font-family:   宋体">代扣税</span> </p><p>448 , &nbsp; --&nbsp; <span style="font-family:   宋体">计件工资</span> </p><p>NULL , &nbsp; -- bLastFlag</p><p>NULL , &nbsp; -- vStatus1</p><p>NULL , &nbsp; -- nStatus2</p><p>NULL , &nbsp; -- iRecordID</p><p>38.3 , &nbsp; --&nbsp; <span style="font-family:   宋体">代付税</span> </p><p>3448.38 &nbsp; , --&nbsp; <span style="font-family:   宋体">年终奖</span> </p><p>32.23 &nbsp; , --&nbsp; <span style="font-family:   宋体">年终奖代扣税</span> &nbsp;</p><p>449.3 &nbsp; , --&nbsp; <span style="font-family:   宋体">工资代扣税</span> </p><p>22.82 &nbsp; , --&nbsp; <span style="font-family:   宋体">扣税合计</span> </p><p>382.3 &nbsp; , --&nbsp; <span style="font-family:   宋体">年终奖代付税</span> &nbsp;</p><p>373.8 &nbsp; , --&nbsp; <span style="font-family:   宋体">工资代付税</span> </p><p>1 , &nbsp; --&nbsp; <span style="font-family:   宋体">工资级别</span> </p><p>2 , &nbsp; --&nbsp; <span style="font-family:   宋体">工资序列</span> </p><p>3 , &nbsp; --&nbsp; <span style="font-family:   宋体">工资等级</span> </p><p>4 , &nbsp; --&nbsp; <span style="font-family:   宋体">工资档次</span> </p><p>5 , &nbsp; --&nbsp; <span style="font-family:   宋体">年岗位技能工资</span> &nbsp;</p><p>8000 , &nbsp; --&nbsp; <span style="font-family:   宋体">月工资</span> </p><p>4000 , &nbsp; --&nbsp; <span style="font-family:   宋体">月基薪</span> </p><p>2000 , &nbsp; --&nbsp; <span style="font-family:   宋体">月绩效</span> </p><p>283.83 &nbsp; , --&nbsp; <span style="font-family:   宋体">年功工资</span> </p><p>44.38 &nbsp; , --&nbsp; <span style="font-family:   宋体">加班工资</span> </p><p>4.38 , &nbsp; --&nbsp; <span style="font-family:   宋体">月预扣风险金</span> &nbsp;</p><p>34.82 &nbsp; , --&nbsp; <span style="font-family:   宋体">社保基数</span> </p><p>44.83 &nbsp; , --&nbsp; <span style="font-family:   宋体">公积金基数</span> </p><p>442.83 &nbsp; , --&nbsp; <span style="font-family:   宋体">养老保险金</span> </p><p>32 , &nbsp; --&nbsp; <span style="font-family:   宋体">医疗保险金</span> </p><p>443.8 &nbsp; , --&nbsp; <span style="font-family:   宋体">失业保险金</span> </p><p>44.38 &nbsp; , --&nbsp; <span style="font-family:   宋体">生育保险金</span> </p><p>33.38 &nbsp; , --&nbsp; <span style="font-family:   宋体">住房公积金</span> </p><p>44.38 &nbsp; , --&nbsp; <span style="font-family:   宋体">社保调整</span> </p><p>1903.8, &nbsp; -- &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <span style="font-family:宋体">计税金额</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</p><p>43.11, &nbsp; -- &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <span style="font-family:宋体">其他免税项目</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</p><p>7889.34, &nbsp; -- &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <span style="font-family:宋体">应发小计</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</p><p>48.3, &nbsp; -- &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <span style="font-family:宋体">通讯费扣款</span>&nbsp;&nbsp;&nbsp;&nbsp;</p><p>889.2, &nbsp; -- &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <span style="font-family:宋体">五险一金扣款</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</p><p>37.38, &nbsp; -- &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <span style="font-family:宋体">病事缺扣款</span>&nbsp;&nbsp;&nbsp;&nbsp;</p><p>28.77, &nbsp; -- &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <span style="font-family:宋体">迟到扣款</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</p><p>12.38, &nbsp; -- &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <span style="font-family:宋体">上月校错</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</p><p>1500, &nbsp; -- &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <span style="font-family:宋体">车贴</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</p><p>38.84, &nbsp; -- &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <span style="font-family:宋体">财务挂账</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</p><p>38.83, &nbsp; -- &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <span style="font-family:宋体">消财务挂账</span>&nbsp;&nbsp;&nbsp;&nbsp;</p><p>503.38, &nbsp; -- &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <span style="font-family:宋体">扣款小计</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</p><p>3834.2, &nbsp; -- &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <span style="font-family:宋体">一次性绩效发放</span>&nbsp;&nbsp;&nbsp;&nbsp;</p><p>889.43, &nbsp; -- <span style="font-family:宋体">季度绩效补差</span></p><p>48.38, &nbsp; -- <span style="font-family:宋体">风险金调差</span></p><p>28, -- &nbsp; <span style="font-family:宋体">本月实际计薪天数</span></p><p>238.48, &nbsp; -- <span style="font-family:宋体">返风险金</span></p><p>1000, &nbsp; -- <span style="font-family:宋体">实习补助标准</span></p><p>100, &nbsp; -- <span style="font-family:宋体">本月出勤率</span></p><p>2, -- <span style="font-family:宋体">绩效考勤等级</span></p><p>448.38, &nbsp; -- <span style="font-family:宋体">绩效摊销</span></p><p>343.28, &nbsp; -- <span style="font-family:宋体">创新先进个人奖励</span></p><p>13, -- &nbsp; <span style="font-family:宋体">缺勤天数</span></p><p>12, -- &nbsp; <span style="font-family:宋体">平时加班天数</span></p><p>11, -- &nbsp; <span style="font-family:宋体">迟到次数</span></p><p>22, -- &nbsp; <span style="font-family:宋体">周末加班天数</span></p><p>24&nbsp; -- <span style="font-family:宋体">节假日加班天数</span></p><p>)</p></td><td width="2" valign="top" height="120" style="border-width: medium 1px 1px medium; border-style: none solid solid none; border-color: -moz-use-text-color black black -moz-use-text-color; padding: 0px 7px;"><p>Pmp<span style="font-family:宋体">目标</span></p><p><span style="font-family:   宋体">存出过程:</span> pmpxzin</p></td><td width="3" valign="top" height="120" style="border-width: medium 1px 1px medium; border-style: none solid solid none; border-color: -moz-use-text-color black black -moz-use-text-color; padding: 0px 7px;"><p>cgzdlname,&nbsp; -- <span style="font-family:宋体">工资大类</span></p><p>cgzgradenum &nbsp; , -- <span style="font-family:宋体">类别编码</span></p><p>cgzgradename &nbsp; , -- <span style="font-family:宋体">类别名称</span></p><p>cpsnnum &nbsp; , -- <span style="font-family:宋体">人员编码</span></p><p>cDeptNum &nbsp; , -- <span style="font-family:宋体">部门编码</span></p><p>iYear &nbsp; , -- <span style="font-family:宋体">年份</span></p><p>iMonth &nbsp; , -- <span style="font-family:宋体">月份</span></p><p>yingfaheji &nbsp; , --&nbsp; <span style="font-family:   宋体">应发合计</span> </p><p>koukuanheji &nbsp; , --&nbsp; <span style="font-family:   宋体">扣款合计</span> </p><p>shifaheji &nbsp; , --&nbsp; <span style="font-family:   宋体">实发合计</span> </p><p>benyuekouling &nbsp; , --&nbsp; <span style="font-family:   宋体">本月扣零</span> </p><p>shangyuekouling &nbsp; , --&nbsp; <span style="font-family:   宋体">上月扣零</span> </p><p>daikoushui &nbsp; , --&nbsp; <span style="font-family:   宋体">代扣税</span> </p><p>jijiangongzi &nbsp; , --&nbsp; <span style="font-family:   宋体">计件工资</span> </p><p>daifushui &nbsp; , --&nbsp; <span style="font-family:   宋体">代付税</span> </p><p>nianzhongjiang &nbsp; , --&nbsp; <span style="font-family:   宋体">年终奖</span> </p><p>nianzhongjiangdaikou &nbsp; , --&nbsp; <span style="font-family:   宋体">年终奖代扣税</span> &nbsp;</p><p>gongzidaikoushui &nbsp; , --&nbsp; <span style="font-family:   宋体">工资代扣税</span> </p><p>koushuiheji &nbsp; , --&nbsp; <span style="font-family:   宋体">扣税合计</span> </p><p>nianzhongjiangdaifus &nbsp; , --&nbsp; <span style="font-family:   宋体">年终奖代付税</span> &nbsp;</p><p>gongzidaifushui &nbsp; , --&nbsp; <span style="font-family:   宋体">工资代付税</span> </p><p>gongzijibie &nbsp; , --&nbsp; <span style="font-family:   宋体">工资级别</span> </p><p>gongzixulie &nbsp; , --&nbsp; <span style="font-family:   宋体">工资序列</span> </p><p>gongzidengji &nbsp; , --&nbsp; <span style="font-family:   宋体">工资等级</span> </p><p>gongzidangci &nbsp; , --&nbsp; <span style="font-family:   宋体">工资档次</span> </p><p>niangangweijinengong &nbsp; , --&nbsp; <span style="font-family:   宋体">年岗位技能工资</span> &nbsp;</p><p>yuegongzi &nbsp; , --&nbsp; <span style="font-family:   宋体">月工资</span> </p><p>yuejixin &nbsp; , --&nbsp; <span style="font-family:   宋体">月基薪</span> </p><p>yuejixiao &nbsp; , --&nbsp; <span style="font-family:   宋体">月绩效</span> </p><p>niangonggongzi &nbsp; , --&nbsp; <span style="font-family:   宋体">年功工资</span> </p><p>jiabangongzi &nbsp; , --&nbsp; <span style="font-family:   宋体">加班工资</span> </p><p>yueyukoufengxianjin &nbsp; , --&nbsp; <span style="font-family:   宋体">月预扣风险金</span> &nbsp;</p><p>shebaojishu &nbsp; , --&nbsp; <span style="font-family:   宋体">社保基数</span> </p><p>gongjijinjishu &nbsp; , --&nbsp; <span style="font-family:   宋体">公积金基数</span> </p><p>yanglaobaoxianjin &nbsp; , --&nbsp; <span style="font-family:   宋体">养老保险金</span> </p><p>yiliaobaoxianjin &nbsp; , --&nbsp; <span style="font-family:   宋体">医疗保险金</span> </p><p>shiyebaoxianjin &nbsp; , --&nbsp; <span style="font-family:   宋体">失业保险金</span> </p><p>shengyubaoxianjin &nbsp; , --&nbsp; <span style="font-family:   宋体">生育保险金</span> </p><p>zhufanggongjijin &nbsp; , --&nbsp; <span style="font-family:   宋体">住房公积金</span> </p><p>shebaodiaozheng &nbsp; , --&nbsp; <span style="font-family:   宋体">社保调整</span> </p><p>jishuijine &nbsp; , --&nbsp; <span style="font-family:   宋体">计税金额</span> </p><p>qitamianshuixiangmu &nbsp; , --&nbsp; <span style="font-family:   宋体">其他免税项目</span> &nbsp;</p><p>yingfaxiaoji &nbsp; , --&nbsp; <span style="font-family:   宋体">应发小计</span> </p><p>tongxunfeikoukuan &nbsp; , --&nbsp; <span style="font-family:   宋体">通讯费扣款</span> </p><p>wuxianyijinkoukuan &nbsp; , --&nbsp; <span style="font-family:   宋体">五险一金扣款</span> &nbsp;</p><p>bingshiquekoukuan &nbsp; , --&nbsp; <span style="font-family:   宋体">病事缺扣款</span> </p><p>chidaokoukuan &nbsp; , --&nbsp; <span style="font-family:   宋体">迟到扣款</span> </p><p>shangyuexiaocuo &nbsp; , --&nbsp; <span style="font-family:   宋体">上月校错</span> </p><p>chetie &nbsp; , --&nbsp; <span style="font-family:   宋体">车贴</span> </p><p>caiwuguazhang &nbsp; , --&nbsp; <span style="font-family:   宋体">财务挂账</span> </p><p>xiaocaiwuguazhang &nbsp; , --&nbsp; <span style="font-family:   宋体">消财务挂账</span> </p><p>koukuanxiaoji &nbsp; , --&nbsp; <span style="font-family:   宋体">扣款小计</span> </p><p>yicixingjixiaofafang &nbsp; , --&nbsp; <span style="font-family:   宋体">一次性绩效发放</span> &nbsp;</p><p>jidujixiaobucha &nbsp; , -- <span style="font-family:宋体">季度绩效补差</span></p><p>fengxianjindiaocha &nbsp; , -- <span style="font-family:宋体">风险金调差</span></p><p>benyueshijijixintian &nbsp; , -- <span style="font-family:宋体">本月实际计薪天数</span></p><p>fanfengxianjin &nbsp; , -- <span style="font-family:宋体">返风险金</span></p><p>shixibuzhubiaozhun &nbsp; , -- <span style="font-family:宋体">实习补助标准</span></p><p>benyuechuqinlv &nbsp; , -- <span style="font-family:宋体">本月出勤率</span></p><p>jixiaokaoqindengji &nbsp; , -- <span style="font-family:宋体">绩效考勤等级</span></p><p>jixiaotanxiao &nbsp; , -- <span style="font-family:宋体">绩效摊销</span></p><p>chuangxinxianjingere &nbsp; , -- <span style="font-family:宋体">创新先进个人奖励</span></p><p>queqintianshu &nbsp; , -- <span style="font-family:宋体">缺勤天数</span></p><p>pingshijiabantianshu &nbsp; , -- <span style="font-family:宋体">平时加班天数</span></p><p>chidaocishu &nbsp; , -- <span style="font-family:宋体">迟到次数</span></p><p>zhoumojiabantianshu &nbsp; , -- <span style="font-family:宋体">周末加班天数</span></p><p>jiejiarijiabantiansh&nbsp; -- <span style="font-family:宋体">节假日加班天数</span></p><p><span style="font-family:   宋体">(</span>67<span style="font-family:宋体">个字段)</span></p></td><td width="39" valign="top" height="120" style="border-width: medium 1px 1px medium; border-style: none solid solid none; border-color: -moz-use-text-color black black -moz-use-text-color; padding: 0px 7px;"><br></td><td width="10" valign="top" height="120" style="border-width: medium 1px 1px medium; border-style: none solid solid none; border-color: -moz-use-text-color black black -moz-use-text-color; padding: 0px 7px;"><br></td></tr><tr style=";height:216px"><td width="2" valign="top" height="216" style="border-width: medium 1px 1px; border-style: none solid solid; border-color: -moz-use-text-color black black; -moz-border-top-colors: none; -moz-border-right-colors: none; -moz-border-bottom-colors: none; -moz-border-left-colors: none; border-image: none; padding: 0px 7px;"><p><span style="font-family:   宋体">请假同步:</span></p><p>Pmp<span style="font-family:宋体">请假单终审后传递到</span>u8</p></td><td width="5" valign="top" height="216" style="border-width: medium 1px 1px medium; border-style: none solid solid none; border-color: -moz-use-text-color black black -moz-use-text-color; padding: 0px 7px;"><p>Pmp<span style="font-family:宋体">数据源视图:</span> pmpqjsurview</p></td><td width="5" valign="top" height="216" style="border-width: medium 1px 1px medium; border-style: none solid solid none; border-color: -moz-use-text-color black black -moz-use-text-color; padding: 0px 7px;"><p>yongyouorderno` &nbsp; AS <span style="font-family:宋体">创建人编码</span>,</p><p>mis_auto_ucjcm.`jieshuriqi&nbsp; AS <span style="font-family:宋体">结束时间</span>,</p><p>&nbsp;mis_auto_dtics.`u8leixingbianma` AS <span style="font-family:宋体">请假类型</span>,</p><p>&nbsp;ryinfoshenhe.name AS <span style="font-family:宋体">批准人</span>,</p><p>&nbsp;ryinfo.`name` AS <span style="font-family:宋体">创建人名</span>,</p><p>&nbsp;mis_auto_ucjcm.`kaishiriqi`&nbsp; AS <span style="font-family:宋体">开始时间</span>,</p><p>FROM_UNIXTIME(mis_auto_ucjcm.`createtime`,'%Y-%m-%d &nbsp; %H:%i:%s')&nbsp; AS <span style="font-family:宋体">创建时间</span>,</p><p>&nbsp;ryinfoqingjr.yongyouorderno AS <span style="font-family:宋体">请假人编码</span>,</p><p>&nbsp;mis_auto_ucjcm.qingjiashiyou AS <span style="font-family:宋体">请假原因</span>,</p><p>&nbsp;'' AS <span style="font-family:宋体">备注</span>,</p><p>&nbsp;mis_auto_ucjcm.`kaishiriqi`&nbsp; AS <span style="font-family:宋体">计划时间</span>,</p><p>&nbsp;ryinfoshenhe.yongyouorderno&nbsp; AS <span style="font-family:宋体">审核人编码</span>,</p><p>&nbsp;ryinfoshenhe.name AS <span style="font-family:宋体">审核人</span>,</p><p>&nbsp;process_info_history.`dotime` AS <span style="font-family:宋体">审核时间</span> ,</p><p>(CASE &nbsp; WHEN mis_auto_ucjcm.status=1 THEN '<span style="font-family:宋体">否</span>'</p><p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; WHEN mis_auto_ucjcm.status=0 THEN '<span style="font-family:宋体">是</span>'</p><p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; END ) AS <span style="font-family:宋体">审核状态</span></p><p>&nbsp;</p></td><td width="30" valign="top" height="216" style="border-width: medium 1px 1px medium; border-style: none solid solid none; border-color: -moz-use-text-color black black -moz-use-text-color; padding: 0px 7px;"><p><span style="font-family:   宋体">调用实例:</span></p><p>&nbsp;</p><p>exec &nbsp; pmpqjwsc -- <span style="font-family:宋体">请假存储过程</span>&nbsp;&nbsp;&nbsp; <span style="font-family:宋体">调试</span></p><p>&nbsp;'100005', --&nbsp; &nbsp; <span style="font-family:宋体">创建人编码</span></p><p>&nbsp;'2015-07-31 17:00'&nbsp; ,&nbsp;&nbsp; &nbsp; -- <span style="font-family:宋体">结束时间</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</p><p>&nbsp;'BS00'&nbsp;&nbsp; &nbsp; ,&nbsp; -- <span style="font-family:宋体">请假类型</span></p><p>&nbsp;'<span style="font-family:宋体">批准人名</span>'&nbsp;&nbsp; , -- <span style="font-family:宋体">批准人</span></p><p>&nbsp;'<span style="font-family:宋体">周庆红</span>'&nbsp;&nbsp; ,&nbsp; --&nbsp; <span style="font-family:宋体">创建人名</span></p><p>&nbsp;'2015-07-31 17:00'&nbsp; ,&nbsp;&nbsp;&nbsp; &nbsp; --&nbsp;&nbsp; <span style="font-family:宋体">开始日期</span>&nbsp;&nbsp; &nbsp;</p><p>&nbsp;'2015-07-31 17:00'&nbsp; ,&nbsp;&nbsp;&nbsp; &nbsp; --&nbsp; <span style="font-family:宋体">创建日期</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</p><p>&nbsp;'100005'&nbsp; &nbsp; ,&nbsp;&nbsp; --<span style="font-family:宋体">请假人编码</span></p><p>&nbsp;'<span style="font-family:宋体">请假原因</span>'&nbsp; , --&nbsp;&nbsp; <span style="font-family:宋体">请假原因</span></p><p>&nbsp;' <span style="font-family:宋体">备注说明</span> ' ,&nbsp;&nbsp;&nbsp; --<span style="font-family:宋体">备注</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</p><p>&nbsp;'2015-07-31 17:00'&nbsp;&nbsp; ,--<span style="font-family:宋体">计划时间</span></p><p>&nbsp;'100005' , -- <span style="font-family:   宋体">审核人编码</span>&nbsp;</p><p>&nbsp;'<span style="font-family:宋体">周庆红</span>'&nbsp;&nbsp; , -- <span style="font-family:宋体">审核人</span>&nbsp;</p><p>&nbsp;'2015-07-31 17:00'&nbsp; ,&nbsp; -- &nbsp; <span style="font-family:宋体">审核时间</span>&nbsp;</p><p>&nbsp;1 &nbsp;-- <span style="font-family:宋体">审核状态</span></p><p>&nbsp;</p><p>&nbsp;</p></td><td width="2" valign="top" height="216" style="border-width: medium 1px 1px medium; border-style: none solid solid none; border-color: -moz-use-text-color black black -moz-use-text-color; padding: 0px 7px;"><p><span style="font-family:   宋体">目标:</span>U8<span style="font-family:宋体">存出过程</span> pmpqjwsc</p></td><td width="3" valign="top" height="216" style="border-width: medium 1px 1px medium; border-style: none solid solid none; border-color: -moz-use-text-color black black -moz-use-text-color; padding: 0px 7px;"><p>exec &nbsp; pmpqjwsc -- <span style="font-family:宋体">请假存储过程</span>&nbsp;&nbsp;&nbsp; <span style="font-family:宋体">调试</span></p><p>&nbsp;'100005', --&nbsp; &nbsp; <span style="font-family:宋体">创建人编码</span></p><p>&nbsp;'2015-07-31 17:00'&nbsp; ,&nbsp;&nbsp; &nbsp; -- <span style="font-family:宋体">结束时间</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</p><p>&nbsp;'BS00'&nbsp;&nbsp; &nbsp; ,&nbsp; -- <span style="font-family:宋体">请假类型</span></p><p>&nbsp;'<span style="font-family:宋体">批准人名</span>'&nbsp;&nbsp; , -- <span style="font-family:宋体">批准人</span></p><p>&nbsp;'<span style="font-family:宋体">周庆红</span>'&nbsp;&nbsp; ,&nbsp; --&nbsp; <span style="font-family:宋体">创建人名</span></p><p>&nbsp;'2015-07-31 17:00'&nbsp; ,&nbsp;&nbsp;&nbsp; &nbsp; --&nbsp;&nbsp; <span style="font-family:宋体">开始日期</span>&nbsp;&nbsp; &nbsp;</p><p>&nbsp;'2015-07-31 17:00'&nbsp; ,&nbsp;&nbsp;&nbsp; &nbsp; --&nbsp; <span style="font-family:宋体">创建日期</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</p><p>&nbsp;'100005'&nbsp; &nbsp; ,&nbsp;&nbsp; -- <span style="font-family:宋体">请假人</span></p><p>&nbsp;'<span style="font-family:宋体">请假原因</span>'&nbsp; , --&nbsp;&nbsp; <span style="font-family:宋体">请假原因</span></p><p>&nbsp;' <span style="font-family:宋体">备注说明</span> ' ,&nbsp;&nbsp;&nbsp; --<span style="font-family:宋体">备注</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</p><p>&nbsp;'2015-07-31 17:00'&nbsp;&nbsp; ,--<span style="font-family:宋体">计划时间</span></p><p>&nbsp;'100005' , -- <span style="font-family:   宋体">审核人编码</span> &nbsp;</p><p>&nbsp;'<span style="font-family:宋体">周庆红</span>'&nbsp;&nbsp; , -- <span style="font-family:宋体">审核人</span>&nbsp;</p><p>&nbsp;'2015-07-31 17:00'&nbsp; ,&nbsp; -- &nbsp; <span style="font-family:宋体">审核时间</span>&nbsp;</p><p>&nbsp;1</p></td><td width="39" valign="top" height="216" style="border-width: medium 1px 1px medium; border-style: none solid solid none; border-color: -moz-use-text-color black black -moz-use-text-color; padding: 0px 7px;"><br></td><td width="10" valign="top" height="216" style="border-width: medium 1px 1px medium; border-style: none solid solid none; border-color: -moz-use-text-color black black -moz-use-text-color; padding: 0px 7px;"><br></td></tr><tr style=";height:216px"><td width="2" valign="top" height="216" style="border-width: medium 1px 1px; border-style: none solid solid; border-color: -moz-use-text-color black black; -moz-border-top-colors: none; -moz-border-right-colors: none; -moz-border-bottom-colors: none; -moz-border-left-colors: none; border-image: none; padding: 0px 7px;"><p><span style="font-family:   宋体">出差同步:</span></p><p>Pmp<span style="font-family:宋体">出差终审后传递到</span>u8</p></td><td width="5" valign="top" height="216" style="border-width: medium 1px 1px medium; border-style: none solid solid none; border-color: -moz-use-text-color black black -moz-use-text-color; padding: 0px 7px;"><p>Pmp<span style="font-family:宋体">数据源视图:</span> pmpccsurview</p></td><td width="5" valign="top" height="216" style="border-width: medium 1px 1px medium; border-style: none solid solid none; border-color: -moz-use-text-color black black -moz-use-text-color; padding: 0px 7px;"><p>ryinfo.yongyouorderno &nbsp; AS <span style="font-family:宋体">创建人编码</span>,</p><p>mis_auto_xeyis.`chuchajieshuoriqi` &nbsp; AS <span style="font-family:宋体">结束时间</span>,</p><p>ryinfochuc.`name`AS &nbsp; <span style="font-family:宋体">批准人</span>,</p><p>ryinfo.`name` &nbsp; AS <span style="font-family:宋体">创建人</span>,</p><p>mis_auto_xeyis.chuchakaishiriqi &nbsp; AS <span style="font-family:宋体">开始时间</span>,</p><p>mis_auto_xeyis.`createtime`&nbsp; AS <span style="font-family:宋体">创建时间</span>,</p><p>ryinfochucr.yongyouorderno&nbsp; AS <span style="font-family:宋体">出差人编码</span>,</p><p>mis_auto_vqzzh.`name` &nbsp; AS <span style="font-family:宋体">出差类型</span>,</p><p>&nbsp;mis_auto_xeyis.chuchashiyou AS <span style="font-family:宋体">出差事由</span>,</p><p>&nbsp;'' AS <span style="font-family:宋体">备注</span>,</p><p>ryinfochuc.`name` &nbsp; AS <span style="font-family:宋体">审核人名</span>,</p><p>process_info_history.`dotime` &nbsp; AS <span style="font-family:宋体">审核时间</span>,</p><p>(CASE &nbsp; WHEN mis_auto_xeyis.`status`='0'&nbsp; THEN &nbsp; '<span style="font-family:宋体">是</span>'</p><p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; WHEN mis_auto_xeyis.`status`='1' THEN '<span style="font-family:宋体">否</span>'&nbsp;</p><p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; END&nbsp;&nbsp;&nbsp; &nbsp; ) AS <span style="font-family:宋体">是否审核</span>,</p><p>ryinfochuc.yongyouorderno &nbsp; AS <span style="font-family:宋体">审核人编码</span>,</p></td><td width="30" valign="top" height="216" style="border-width: medium 1px 1px medium; border-style: none solid solid none; border-color: -moz-use-text-color black black -moz-use-text-color; padding: 0px 7px;"><p>&nbsp;</p><p>exec &nbsp; pmpcc&nbsp;&nbsp; --<span style="font-family:宋体">出差调试</span> </p><p>&nbsp;&nbsp; 'demo', -- <span style="font-family:   宋体">创建人编码</span></p><p>&nbsp;&nbsp; '2015-08-04 00:00', -- <span style="font-family:宋体">结束时间</span></p><p>&nbsp;&nbsp; 'aaa', -- <span style="font-family:   宋体">批准人</span></p><p>&nbsp;&nbsp; 'demo', -- <span style="font-family:   宋体">创建人</span></p><p>&nbsp;&nbsp; '2015-08-03 00:00', -- <span style="font-family:宋体">开始时间</span></p><p>&nbsp;&nbsp; '2015-08-03 11:47:04', -- <span style="font-family:宋体">创建时间</span></p><p>&nbsp;&nbsp; '100001',&nbsp; &nbsp; -- <span style="font-family:宋体">出差人编码</span></p><p>&nbsp;&nbsp; 'DS01',&nbsp; &nbsp; -- <span style="font-family:宋体">出差类型</span></p><p>&nbsp;&nbsp; 'bbb', -- <span style="font-family:   宋体">出差事由</span></p><p>&nbsp;&nbsp; 'ccc111' , -- <span style="font-family:宋体">备注</span></p><p>&nbsp;&nbsp; 'demo',--&nbsp; &nbsp; <span style="font-family:宋体">审核人名</span>&nbsp;</p><p>&nbsp;&nbsp; '2015-08-03 11:47:04' , --&nbsp; <span style="font-family:宋体">审核时间</span>&nbsp;</p><p>&nbsp;&nbsp; 1 , -- <span style="font-family:   宋体">是否审核</span></p><p>&nbsp;&nbsp; 'demo'&nbsp; &nbsp; --<span style="font-family:宋体">审核人编码</span></p></td><td width="2" valign="top" height="216" style="border-width: medium 1px 1px medium; border-style: none solid solid none; border-color: -moz-use-text-color black black -moz-use-text-color; padding: 0px 7px;"><p>U8<span style="font-family:宋体">目标:存出过程</span> &nbsp;pmpcc&nbsp;&nbsp; &nbsp;</p></td><td width="3" valign="top" height="216" style="border-width: medium 1px 1px medium; border-style: none solid solid none; border-color: -moz-use-text-color black black -moz-use-text-color; padding: 0px 7px;"><p>&nbsp;</p><p>&nbsp;exec pmpcc&nbsp;&nbsp; &nbsp; --<span style="font-family:宋体">出差调试</span> </p><p>&nbsp;&nbsp; 'demo', -- <span style="font-family:   宋体">创建人编码</span></p><p>&nbsp;&nbsp; '2015-08-04 00:00', -- <span style="font-family:宋体">结束时间</span></p><p>&nbsp;&nbsp; 'aaa', -- <span style="font-family:   宋体">批准人</span></p><p>&nbsp;&nbsp; 'demo', -- <span style="font-family:   宋体">创建人</span></p><p>&nbsp;&nbsp; '2015-08-03 00:00', -- <span style="font-family:宋体">开始时间</span></p><p>&nbsp;&nbsp; '2015-08-03 11:47:04', -- <span style="font-family:宋体">创建时间</span></p><p>&nbsp;&nbsp; '100001',&nbsp; &nbsp; -- <span style="font-family:宋体">出差人编码</span></p><p>&nbsp;&nbsp; 'DS01',&nbsp; &nbsp; -- <span style="font-family:宋体">出差类型</span></p><p>&nbsp;&nbsp; 'bbb', -- <span style="font-family:   宋体">出差事由</span></p><p>&nbsp;&nbsp; 'ccc111' , -- <span style="font-family:宋体">备注</span></p><p>&nbsp;&nbsp; 'demo',--&nbsp; &nbsp; <span style="font-family:宋体">审核人名</span>&nbsp;</p><p>&nbsp;&nbsp; '2015-08-03 11:47:04' , --&nbsp; <span style="font-family:宋体">审核时间</span>&nbsp;</p><p>&nbsp;&nbsp; 1 , -- <span style="font-family:   宋体">是否审核</span></p><p>&nbsp;&nbsp; 'demo'&nbsp; &nbsp; --<span style="font-family:宋体">审核人编码</span></p><p>&nbsp;</p></td><td width="39" valign="top" height="216" style="border-width: medium 1px 1px medium; border-style: none solid solid none; border-color: -moz-use-text-color black black -moz-use-text-color; padding: 0px 7px;"><br></td><td width="10" valign="top" height="216" style="border-width: medium 1px 1px medium; border-style: none solid solid none; border-color: -moz-use-text-color black black -moz-use-text-color; padding: 0px 7px;"><br></td></tr></tbody></table>\t
code;
        $content = htmlToWordXml($content);
        // 		dump($content);
        // 		exit;
        $PHPWord = new PHPWord();
        // 		dump(htmlToWordXml($content));
        // 		exit;
        $docfile = UPLOAD_SampleWord . "4444.docx";
        $filenameUTF8 = UPLOAD_SampleWord . "5555.docx";
        $document = $PHPWord->loadTemplate($docfile);
        $document->clearAllBiaoji();
        $content = <<<code
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<w:document xmlns:ve="http://schemas.openxmlformats.org/markup-compatibility/2006" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:r="http://schemas.openxmlformats.org/officeDocument/2006/relationships" xmlns:m="http://schemas.openxmlformats.org/officeDocument/2006/math" xmlns:v="urn:schemas-microsoft-com:vml" xmlns:wp="http://schemas.openxmlformats.org/drawingml/2006/wordprocessingDrawing" xmlns:w10="urn:schemas-microsoft-com:office:word" xmlns:w="http://schemas.openxmlformats.org/wordprocessingml/2006/main" xmlns:wne="http://schemas.microsoft.com/office/word/2006/wordml"><w:body>{$content}</w:body></w:document>
code;
        // 		dump($content);exit;
        // 		$bookNamearr = array();
        // 		$bookNamearr["wang"] = array(
        // 				"name" => "wang",
        // 				"showname" => "",
        // 				"original" => $content,
        // 				"value" => $content,
        // 				"is_datatable" => 0,
        // 				"istestarea" => 1
        // 		);
        // 		foreach($bookNamearr as $k => $v)
        // 		{
        // 			if($v["is_datatable"]){
        // 				$data = array();
        // 				$data["showname"] = $v["showname"];
        // 				$data["value"]= $v["value"];
        // 				$data["showtype"]= $v["showtype"]!==NULL?$v["showtype"]:0;
        // 				$data["showtitle"]= $v["showtitle"]!==NULL?$v["showtitle"]:0;
        // 				if(isset($v["colORrow"])){
        // 					$data["colORrow"] = $v["colORrow"];
        // 				}
        // 				if(is_array($v["value"]) && !isset($v["colORrow"])){
        // 					foreach($v["value"] as $kk => $vv){
        // 						$data["titleArr"][] = empty($vv["showname"])?"":$vv["showname"];
        // 					}
        // 				}
        //  				$document->setValue($v["name"],$data);
        // 			}else{
        // 				$document->setValue($v["name"],$v);
        // 			}
        // 		}
        // 		$document->clearTemplateTag();
        // 		$document->save($filenameUTF8);
        // 		$filenameUTF8 = UPLOAD_SampleWord."6789.docx";
        // 		$document = $PHPWord->loadTemplate($imgurl);
        $document->setStr($content);
        $document->save($filenameUTF8);
        header("Cache-Control: public");
        header("Content-Type: application/force-download");
        header("Content-Disposition: attachment; filename=" . basename($filenameUTF8));
        readfile($filenameUTF8);
    }
예제 #8
0
<?php

require_once '../PHPWord.php';
$PHPWord = new PHPWord();
$document = $PHPWord->loadTemplate('tort.docx');
$document->setValue('Value1', 'Sun');
$document->setValue('Value2', 'Mercury');
$document->setValue('Value3', 'Venus');
$document->setValue('Value4', 'Earth');
$document->setValue('Value5', 'Mars');
$document->setValue('Value6', 'Jupiter');
$document->setValue('Value7', 'Saturn');
$document->setValue('Value8', 'Uranus');
$document->setValue('Value9', 'Neptun');
$document->setValue('Value10', 'Pluto');
$document->setValue('weekday', date('l'));
$document->setValue('time', date('H:i'));
$document->save('Solarsystem.doc');
예제 #9
0
include 'functions.php';
// ----------------------------------------------------------------------------------------
$PHPWord = new PHPWord();
if ($_POST['type_doc'] == 'pre_dogovor') {
    //-------------------------------------------------------------------------------------
    // Принятие данных с форматом datepicker и обработка их,
    // информация приходит в виде объекта данных string с инфой: dd.mm.yy
    //-------------------------------------------------------------------------------------
    // Дата заключения договора
    $pre_date_of_dogovor = DateTime::createFromFormat('d.m.Y', $_POST['pre_date_of_dogovor']);
    $pre_day_of_dogovor = $pre_date_of_dogovor->format('d');
    $pre_month_of_dogovor = $pre_date_of_dogovor->format('m');
    $pre_year_of_dogovor = $pre_date_of_dogovor->format('Y');
    // Если не требуется распарсить строку, то можно сразу же обращаться к данным через супермассив $_POST
    //-------------------------------------------------------------------------------------
    $document = $PHPWord->loadTemplate('pre_dogovor.docx');
    //шаблон
    // Замена переменных
    $document->setValue('city', $_POST['pre_placeOfDogovor']);
    //Место заключения договора
    $document->setValue('dayOfDogovor', get_day_from_number($pre_day_of_dogovor));
    //Дата заключения договора: день
    $document->setValue('monthOfDogovor', get_month_from_number($pre_month_of_dogovor));
    //Дата заключения договора: месяц
    $document->setValue('yearOfDogovor', get_year_from_number($pre_year_of_dogovor));
    //Дата заключения договора: год
    $document->setValue('pre_fio', $_POST['pre_fio']);
    //ФИО продавца
    $document->setValue('birthday_of_vendor', $_POST['pre_birthday_of_vendor']);
    //Дата рождения продавца
    $document->setValue('pre_passport', $_POST['pre_passport']);
예제 #10
0
 if ($status == 2) {
     $query = "update CS_REGISTER_CUSTOMER_SERVICE set NOMOR_SURAT_TUNAI = NOMOR_SURAT_TUNAI + 1";
     ex_false($conn->execute($query), $query);
 } else {
     if ($status == 1) {
         $query = "update CS_REGISTER_CUSTOMER_SERVICE set NOMOR_SURAT_KPR = NOMOR_SURAT_KPR + 1";
         ex_false($conn->execute($query), $query);
     }
 }
 $query = "update RENCANA set NO_SURAT5 = '{$nomor_surat}', TANGGAL_SURAT5 = CONVERT(DATETIME,GETDATE(),105) \n\t\t\tWHERE KODE_BLOK = '{$id}'\n\t\t\tAND TANGGAL >= CONVERT(DATETIME,'01-{$bln}-{$thn}',105) \n\t\t\tAND TANGGAL < CONVERT(DATETIME,'01-{$next_bln}-{$next_thn}',105)";
 ex_false($conn->execute($query), $query);
 $query = "update SPP set STATUS_WANPRESTASI = 1 \n\t\t\tWHERE KODE_BLOK = '{$id}' ";
 ex_false($conn->execute($query), $query);
 // Create a new PHPWord Object
 $PHPWord = new PHPWord();
 $document = $PHPWord->loadTemplate('../../../../../surat/Surat_Wanprestasi.docx');
 //header
 $document->setValue('tanggal_cetak', $tanggal_cetak);
 $document->setValue('nomor_surat', $nomor_surat);
 $document->setValue('nama_pembeli', $nama_pembeli);
 $document->setValue('alamat', $alamat);
 $document->setValue('telepon', $telepon);
 $document->setValue('tanggal_spp', $tanggal_spp);
 $document->setValue('nomor_spp', $nomor_spp);
 $document->setValue('tanggal_ppjb', $tanggal_ppjb);
 $document->setValue('nomor_ppjb', $nomor_ppjb);
 $document->setValue('tanggal_tempo', $tgl_tempo);
 $document->setValue('no_somasi1', $no_somasi1);
 $document->setValue('tgl_somasi1', $tgl_somasi1);
 $document->setValue('no_somasi2', $no_somasi2);
 $document->setValue('tgl_somasi2', $tgl_somasi2);
예제 #11
0
 $nomor_surat_dahulu = $obj->fields['NO_SURAT3'];
 $tanggal_surat_dahulu = kontgl(tgltgl(date("d M Y", strtotime($obj->fields['TANGGAL_SURAT3']))));
 if ($status == 2) {
     $query = "update CS_REGISTER_CUSTOMER_SERVICE set NOMOR_SURAT_TUNAI = NOMOR_SURAT_TUNAI + 1";
     ex_false($conn->execute($query), $query);
 } else {
     if ($status == 1) {
         $query = "update CS_REGISTER_CUSTOMER_SERVICE set NOMOR_SURAT_KPR = NOMOR_SURAT_KPR + 1";
         ex_false($conn->execute($query), $query);
     }
 }
 $query = "update RENCANA set NO_SURAT4 = '{$nomor_surat}', TANGGAL_SURAT4 = CONVERT(DATETIME,GETDATE(),105) \n\t\t\tWHERE KODE_BLOK = '{$id}'\n\t\t\tAND TANGGAL >= CONVERT(DATETIME,'01-{$bln}-{$thn}',105) \n\t\t\tAND TANGGAL < CONVERT(DATETIME,'01-{$next_bln}-{$next_thn}',105)";
 ex_false($conn->execute($query), $query);
 // Create a new PHPWord Object
 $PHPWord = new PHPWord();
 $document = $PHPWord->loadTemplate('../../../../../surat/Surat_Somasi_3.docx');
 //header
 $document->setValue('tanggal_cetak', $tanggal_cetak);
 $document->setValue('nomor_surat', $nomor_surat);
 $document->setValue('nama_pembeli', $nama_pembeli);
 $document->setValue('alamat', $alamat);
 $document->setValue('telepon', $telepon);
 $document->setValue('tanggal_spp', $tanggal_spp);
 $document->setValue('tanggal_tempo', $tgl_tempo);
 $document->setValue('nomor_surat_dahulu', $nomor_surat_dahulu);
 $document->setValue('tanggal_surat_dahulu', $tanggal_surat_dahulu);
 $document->setValue('blok', $blok);
 $document->setValue('nomor', $nomor);
 $document->setValue('kav_bang', $kav_bang);
 $document->setValue('nilai', to_money($nilai) . ".00");
 $document->setValue('bulan', $bulan);
예제 #12
0
// $template = str_replace("{ATTN_NAME}", $row['attn_name'],$template );
// $template = str_replace("{ATTN_PHONE}", $row['attn_phone'],$template);
// $template = str_replace("{ATTN_EMAIL}", $row['attn_name'],$template);
// $template = str_replace("{TEL}", $row['attn_tel'],$template);
// $template = str_replace("{FAX}",  $row['attn_fax'],$template);
// $template = str_replace("{MADETOUR}",   $row['groupprogram_code'],$template);
// if(!empty($row['nationlity'])){
// $template = str_replace("{NATIONLITY}", translate('countries_dom','',$row['nationlity']),$template);
// }
// else{$template = str_replace("{NATIONLITY}", translate('countries_dom','',''),$template); }
// $template = str_replace("{BOOKINGLINE}", $focus->get_bookingroom_detailview($record),$template);
// $template = str_replace("{NOTES}", html_entity_decode(nl2br($row['notes'])),$template);
// $template = str_replace("{CONVENTION}", html_entity_decode(nl2br($row['convention'])),$template);
// $template = str_replace("{COST}", html_entity_decode(nl2br($row['cost'])),$template);
// $template = str_replace("{INCLUDE}", html_entity_decode(nl2br($row['include'])),$template);
// $template = str_replace("{DINING_PLAN}", html_entity_decode(nl2br($row['dining_plan'])),$template);
// if($row['confirmed']== 0 ){
// $template = str_replace("{CONFIRM}", 'No',$template);
// }
// else {$template = str_replace("{CONFIRM}", 'Yes',$template); }
// $template = str_replace("{DATE}", date("d/m/Y",strtotime($row['date'])),$template);
// $template = str_replace("{DEPARMENT}", $row['deparment'],$template);
$PHPWord = new PHPWord();
$document = $PHPWord->loadTemplate('modules/RoomBookings/tpls/roombooking_template.docx');
$document->setValue('To', $row['name']);
$document->setValue('ToAddress', $row['hotel_address']);
$document->setValue('ToContactName', $row['attn_hotel_name']);
$document->setValue('ToContactPhone', $row['attn_hotel_phone']);
$document->setValue('Phone', $row['hotel_tel']);
$document->setValue('Fax', html_entity_decode(nl2br($row['convention'])));
$document->output('modules/RoomBookings/Room-Booking.docx');
예제 #13
0
 public function getDoc($expediente)
 {
     $cliente = $this->mysqli->query('select * from expediente, cliente where id_expediente="' . $expediente . '" and cliente.rfc=expediente.fk_rfc')->fetch_object();
     //$cliente = DB::table('expediente')->where('id_expediente', $expediente)->join('cliente', 'cliente.rfc', '=', 'expediente.fk_rfc')->get()[0];
     $lote = $this->mysqli->query('select * from expediente, solicitud, contrato, contrato_lote, lote, manzana, desarrollo where expediente.id_expediente="' . $expediente . '" and solicitud.fk_expediente=expediente.id_expediente and contrato.fk_solicitud=solicitud.id_solicitud  and contrato_lote.fk_contrato=contrato.id_contrato and lote.id_lote=contrato_lote.fk_lote and manzana.id_manzana=lote.fk_manzana and desarrollo.id_desarrollo=manzana.fk_desarrollo')->fetch_object();
     //$lote=DB::table('expediente')->where('id_expediente', $expediente)->join('solicitud', 'fk_expediente', '=','expediente.id_expediente')->join('contrato', 'contrato.fk_solicitud', '=','solicitud.id_solicitud')->join('contrato_lote','contrato_lote.fk_contrato', '=' ,'contrato.id_contrato')->join('lote','lote.id_lote', '=', 'contrato_lote.fk_lote')->join('manzana', 'manzana.id_manzana', '=', 'lote.fk_manzana')->join('desarrollo', 'desarrollo.id_desarrollo', '=', 'manzana.fk_desarrollo')->get()[0];
     $contrato = $this->mysqli->query('select * from contrato where id_contrato=' . $lote->id_contrato)->fetch_object();
     $categoria = $this->mysqli->query('select * from categoria where id_categoria=' . '"' . $lote->fk_categoria . '"')->fetch_object();
     //$categoria = DB::table('categoria')->where('id_categoria', $lote->fk_categoria)->get()[0];
     $cuenta = $this->mysqli->query('select * from cuenta where fk_contrato=' . $lote->id_contrato)->fetch_object();
     //$cuenta = DB::table('cuenta')->where('fk_contrato', $lote->id_contrato)->get()[0];
     $enganches = Estatica::getObjetos($this->mysqli->query('select * from enganche_parcial where fk_cuenta=' . $cuenta->id_cuenta));
     //$enganches = DB::table('enganche_parcial')->where('fk_cuenta', $cuenta->id_cuenta)->get();
     $partesContrato = DB::table('parte_contrato')->where('fk_desarrollo', $lote->fk_desarrollo)->get();
     $ala_Firma = 0;
     $textoEnganches = '';
     $bool_no_parciales = true;
     for ($e = 0; $e < count($enganches); $e++) {
         if (strtotime($enganches[$e]->fecha_promesa) > strtotime($contrato->fecha_realizacion)) {
             $textoEnganches = $textoEnganches . " Complemento de enganche por \$" . round($enganches[$e]->importe, 2) . ' ' . numtoletras(round($enganches[$e]->importe, 2)) . " que depositara en la fecha " . $enganches[$e]->fecha_promesa;
             $bool_no_parciales = false;
         } else {
             $ala_Firma += $enganches[$e]->importe;
         }
     }
     if ($bool_no_parciales == true) {
         $textoEnganches = 'Ningun enganche parcial.';
     }
     $PHPWord = new PHPWord();
     if ($lote->tipo_operacion == 1) {
         $document = $PHPWord->loadTemplate(dirname(__FILE__) . '/PHPWord/contrato_contado.docx');
     } else {
         $document = $PHPWord->loadTemplate(dirname(__FILE__) . '/PHPWord/Plantilla_Contrato_Credito.docx');
         $document->setValue('Plazo', $lote->plazo);
         $document->setValue('DiaCorte', $lote->dia_corte);
         $document->setValue('PlazoLetra', numtoletras_2($lote->plazo));
         $lote->fecha_inicial_pago = explode('-', $lote->fecha_inicial_pago);
         $document->setValue('IniciaDia', $lote->fecha_inicial_pago[2]);
         for ($parte = 0; $parte < count($partesContrato); $parte++) {
             $document->setValue('Parte' . ($parte + 1), $partesContrato[$parte]->texto);
         }
         $document->setValue('MesInicia', $this->mes($lote->fecha_inicial_pago[1]));
         $document->setValue('AnioInicia', $lote->fecha_inicial_pago[0]);
     }
     $document->setValue('Contrato', $expediente);
     $document->setValue('Cliente', $cliente->nombre . " " . $cliente->ape_pate . " " . $cliente->ape_mate);
     $document->setValue('CP', $cliente->cp);
     if ($cliente->estado_civil == 1) {
         $document->setValue('Edo_Civil', 'Soltero');
         $document->setValue('Regimen', ' ');
     } else {
         $document->setValue('Edo_Civil', 'Casado');
         if ($cliente->regimenMatrimonial == 1) {
             $document->setValue('Regimen', ' bajo el regimen de Bienes mancomunados');
         } else {
             $document->setValue('Regimen', 'bajo el regimen de Bienes separados');
         }
     }
     $document->setValue('Profesion', $cliente->profesion);
     $document->setValue('RFC', $cliente->rfc);
     $document->setValue('CURP', $cliente->curp);
     $document->setValue('Tel_Casa', $cliente->telefono);
     $document->setValue('Tel_Celular', $cliente->movil);
     $document->setValue('Email', $cliente->email);
     $document->setValue('Calle', $cliente->calle);
     $document->setValue('No', $cliente->numero_casa);
     $document->setValue('Colonia', $cliente->colonia);
     $document->setValue('Nacionalidad', $cliente->nacionalidad);
     $document->setValue('Desarrollo', $lote->nombre);
     $document->setValue('Lote', $lote->lote);
     $document->setValue('LoteLetra', numtoletras_2($lote->lote));
     $document->setValue('Manzana', $lote->num_letra);
     $document->setValue('ManzanaLetra', numtoletras_2($lote->num_letra));
     $document->setValue('MtNorte', $lote->metlinor);
     $document->setValue('LindaNorte', $lote->metlinor);
     $document->setValue('MtSur', $lote->metlinsur);
     $document->setValue('LindaSur', $lote->lindasur);
     $document->setValue('MtOriente', $lote->metlinoeste);
     $document->setValue('LindaOriente', $lote->lindaoriente);
     $document->setValue('MtPoniente', $lote->metlineste);
     $document->setValue('LindaPoniente', $lote->lindaponiente);
     $document->setValue('Total', round($categoria->precio * $lote->superficie), 2);
     $document->setValue('TotalLetra', numtoletras(round($categoria->precio * $lote->superficie), 2));
     $document->setValue('Precio_Metro', round($categoria->precio, 2));
     $document->setValue('PrecioMetroLetra', numtoletras(round($categoria->precio, 2)));
     $document->setValue('Superficie', round($lote->superficie, 2));
     $document->setValue('SuperficieLetra', numtoletras_2(round($lote->superficie, 2)));
     $document->setValue('SaldoFinanciar', round($cuenta->saldo_inicial));
     $document->setValue('SaldoFinanciarLetra', numtoletras(round($cuenta->saldo_inicial)));
     $document->setValue('Enganche', round($ala_Firma));
     $document->setValue('EngancheLetra', numtoletras(round($ala_Firma)));
     $document->setValue('Complementos', $textoEnganches);
     $lote->fecha_realizacion = explode("-", $lote->fecha_realizacion);
     $document->setValue('Dia', $lote->fecha_realizacion[2]);
     $document->setValue('Mes', $this->mes($lote->fecha_realizacion[1]));
     $document->setValue('Anio', $lote->fecha_realizacion[0]);
     $document->setValue('Referencia', $lote->fk_referencia);
     $document->setValue('Municipio', $cliente->municipio);
     $document->setValue('Complemento', $cliente->estado);
     if ($lote->tipo_operacion == 1) {
         $document->save($expediente . '_Contado.docx');
     } else {
         $document->save($expediente . '_Credito.docx');
     }
 }
예제 #14
0
    public function GeraOitAlterado() {

	$CData = new Data();


	$SqlOit = "SELECT  * FROM oit_formulario WHERE my_parametro_id = " . $this->MyParametroId . " AND laudo_item_id =" . $this->getLaudoItemId();

	$BD = New Database();

	$Result = $BD->query($SqlOit);


	if ($Result->rowCount() == 0) {
	    $this->setMsg("Não foram encontradas informações para este laudo, não será possível concluir a geração do arquivo\n\n");
	    $this->setStatusGeracao(false);
	}

	$LinhaOit = $Result->fetchAll();


	$Cpf = $this->getCPF();
	$DocOit = !isset($Cpf) ? "CPF " . $this->getCPF() : "RG: " . $this->getRG();

	$_1a = $LinhaOit[0]["1a"];
	$_1b = $LinhaOit[0]["1b"];
	$_2a = $LinhaOit[0]["2a"];
	$_2b_pequenas_opacidades_primarias = $LinhaOit[0]["2b_pequenas_opacidades_primarias"];
	$_2b_pequenas_opacidades_secundarias = $LinhaOit[0]["2b_pequenas_opacidades_secundarias"];
	$_2b_zonas_d = $LinhaOit[0]["2b_zonas_d"];
	$_2c_profusao = $LinhaOit[0]["2c_profusao"];
	$_2c_grandes_opacidades = $LinhaOit[0]["2c_grandes_opacidades"];
	$_3a = $LinhaOit[0]["3a"];
	$_3b_placas_neurais = $LinhaOit[0]["3b_placas_neurais"];
	$_3b_parede_em_perfil_local = $LinhaOit[0]["3b_parede_em_perfil_local"];
	$_3b_parede_em_perfil_calcificacao = $LinhaOit[0]["3b_parede_em_perfil_calcificacao"];
	$_3b_frontal_local = $LinhaOit[0]["3b_frontal_local"];
	$_3b_frontal_calcificacao = $LinhaOit[0]["3b_frontal_calcificacao"];
	$_3b_diafragma_local = $LinhaOit[0]["3b_diafragma_local"];
	$_3b_diafragma_calcificacao = $LinhaOit[0]["3b_diafragma_calcificacao"];
	$_3b_outros_locais_local = $LinhaOit[0]["3b_outros_locais_local"];
	$_3b_outros_locais_calcificacao = $LinhaOit[0]["3b_outros_locais_calcificacao"];
	$_3b_combinado_0d = $LinhaOit[0]["3b_combinado_0d"];
	$_3b_combinado_0e = $LinhaOit[0]["3b_combinado_0e"];
	$_3b_combinado_d = $LinhaOit[0]["3b_combinado_d"];
	$_3b_combinado_e = $LinhaOit[0]["3b_combinado_e"];
	$_3c = $LinhaOit[0]["3c"];
	$_3d_espessamento_pleural_difuso = $LinhaOit[0]["3d_espessamento_pleural_difuso"];
	$_3d_parede_em_perfil_local = $LinhaOit[0]["3d_parede_em_perfil_local"];
	$_3d_parede_em_perfil_calcificacao = $LinhaOit[0]["3d_parede_em_perfil_calcificacao"];
	$_3d_frontal_local = $LinhaOit[0]["3d_frontal_local"];
	$_3d_frontal_calcificacao = $LinhaOit[0]["3d_frontal_calcificacao"];
	$_3d_combinado_0d = $LinhaOit[0]["3d_combinado_0d"];
	$_3d_combinado_0e = $LinhaOit[0]["3d_combinado_0e"];
	$_4a_outras_normalidades = $LinhaOit[0]["4a_outras_normalidades"];
	$_4b_outras_normalidades = $LinhaOit[0]["4b_outras_normalidades"];
	$_4c_comentarios = $LinhaOit[0]["4c_comentarios"];

	$PHPWord = new PHPWord();

	$ArquivoClinica = $this->VerificaDiretorioTemplateOIT();

	$document = $PHPWord->loadTemplate($ArquivoClinica);

	//clínica
	$document->setValue('nome_emp', $this->getRazaoSocialClinica());
	$document->setValue('cnpj_emp', $this->getCnpjClinica());
	$document->setValue('rua_emp', $this->getEnderecoClinica());
	$document->setValue('tel_emp', $this->getTelefoneClinica());
	$document->setValue('cidade_emp', $this->getCidadeClinica());
	$document->setValue('estado_emp', $this->getUFClinica());

	//Funcionário
	$document->setValue('nome_func', $this->getFuncionario());
	$document->setValue('doc_func', $DocOit);
	$document->setValue('empresa_func', $this->getRazaoSocialEmp());
	$document->setValue('dat_func', $this->getDataNascimento());
	$document->setValue('func_funcionario', $this->getFuncao());
	$document->setValue('idade_func', $this->IdadeFunc);
	$document->setValue('tel_func', $this->TelefoneClinica);
	$document->setValue('data_exame_func', $CData->convertDataBrasileira($this->getDataRealizacao()));

	$document->setValue('observacao', "$_4c_comentarios");

	//Marcações no documento
	//1A
	if ($_1a == 1) {
	    $document->setValue('1a1', "X");
	} else {
	    $document->setValue('1a1', "");
	};

	if ($_1a == 2) {
	    $document->setValue('1a2', "X");
	} else {
	    $document->setValue('1a2', "");
	}

	if ($_1a == 3) {
	    $document->setValue('1a3', "X");
	} else {
	    $document->setValue('1a3', "");
	};

	if ($_1a == 4) {
	    $document->setValue('1a4', "X");
	} else {
	    $document->setValue('1a4', "");
	};

	//1B
	if ($_1b == "S") {
	    $document->setValue('1bs', "X");
	} else {
	    $document->setValue('1bs', "");
	};

	if ($_1b == "N") {
	    $document->setValue('1bn', "X");
	} else {
	    $document->setValue('1bn', "");
	}

	//2A
	if ($_2a == "S") {
	    $document->setValue('2as', "X");
	} else {
	    $document->setValue('2as', "");
	}

	if ($_2a == "N") {
	    $document->setValue('2an', "X");
	} else {
	    $document->setValue('2an', "");
	}

	//2B Primária
	if ($_2b_pequenas_opacidades_primarias == "P") {
	    $document->setValue('2bp', "X");
	} else {
	    $document->setValue('2bp', "");
	}

	if ($_2b_pequenas_opacidades_primarias == "Q") {
	    $document->setValue('2bq', "X");
	} else {
	    $document->setValue('2bq', "");
	}

	if ($_2b_pequenas_opacidades_primarias == "R") {
	    $document->setValue('2br', "X");
	} else {
	    $document->setValue('2br', "");
	}

	if ($_2b_pequenas_opacidades_primarias == "S") {
	    $document->setValue('2bs', "X");
	} else {
	    $document->setValue('2bs', "");
	}

	if ($_2b_pequenas_opacidades_primarias == "T") {
	    $document->setValue('2bt', "X");
	} else {
	    $document->setValue('2bt', "");
	}

	if ($_2b_pequenas_opacidades_primarias == "U") {
	    $document->setValue('2bu', "X");
	} else {
	    $document->setValue('2bu', "");
	};

	//2B Secundária
	if ($_2b_pequenas_opacidades_secundarias == "P") {
	    $document->setValue('2bps', "X");
	} else {
	    $document->setValue('2bps', "");
	}

	if ($_2b_pequenas_opacidades_secundarias == "Q") {
	    $document->setValue('2bqs', "X");
	} else {
	    $document->setValue('2bqs', "");
	}

	if ($_2b_pequenas_opacidades_secundarias == "R") {
	    $document->setValue('2brs', "X");
	} else {
	    $document->setValue('2brs', "");
	    ;
	}

	if ($_2b_pequenas_opacidades_secundarias == "S") {
	    $document->setValue('2bss', "X");
	} else {
	    $document->setValue('2bss', "");
	}

	if ($_2b_pequenas_opacidades_secundarias == "T") {
	    $document->setValue('2bts', "X");
	} else {
	    $document->setValue('2bts', "");
	}

	if ($_2b_pequenas_opacidades_secundarias == "U") {
	    $document->setValue('2bus', "X");
	} else {
	    $document->setValue('2bus', "");
	}

	//2C Profusão
	if ($_2c_profusao == "0/-") {
	    $document->setValue('0/-', "X");
	} else {
	    $document->setValue('0/-', "");
	};

	if ($_2c_profusao == "1/0") {
	    $document->setValue('1/0', "X");
	} else {
	    $document->setValue('1/0', "");
	};

	if ($_2c_profusao == "2/1") {
	    $document->setValue('2/1', "X");
	} else {
	    $document->setValue('2/1', "");
	};

	if ($_2c_profusao == "3/2") {
	    $document->setValue('3/2', "X");
	} else {
	    $document->setValue('3/2', "");
	};

	if ($_2c_profusao == "0/0") {
	    $document->setValue('0/0', "X");
	} else {
	    $document->setValue('0/0', "");
	};

	if ($_2c_profusao == "1/1") {
	    $document->setValue('1/1', "X");
	} else {
	    $document->setValue('1/1', "");
	};

	if ($_2c_profusao == "2/2") {
	    $document->setValue('2/2', "X");
	} else {
	    $document->setValue('2/2', "");
	};

	if ($_2c_profusao == "3/3") {
	    $document->setValue('3/3', "X");
	} else {
	    $document->setValue('3/3', "");
	};

	if ($_2c_profusao == "0/1") {
	    $document->setValue('0/1', "X");
	} else {
	    $document->setValue('0/1', "");
	};

	if ($_2c_profusao == "1/2") {
	    $document->setValue('1/2', "X");
	} else {
	    $document->setValue('1/2', "");
	};

	if ($_2c_profusao == "1/2") {
	    $document->setValue('1/2', "X");
	} else {
	    $document->setValue('1/2', "");
	};

	if ($_2c_profusao == "2/3") {
	    $document->setValue('2/3', "X");
	} else {
	    $document->setValue('2/3', "");
	};

	if ($_2c_profusao == "3/+") {
	    $document->setValue('3/+', "X");
	} else {
	    $document->setValue('3/+', "");
	};

	if ($_3a == "S") {
	    $document->setValue('3as', "X");
	    $document->setValue('3an', "");
	} elseif ($_3a == "N") {
	    $document->setValue('3as', "");
	    $document->setValue('3an', "X");
	} else {
	    $document->setValue('3as', "");
	    $document->setValue('3an', "");
	};
	// 3B Placas Pleurais
	if ($_3b_placas_neurais == "S") {
	    $document->setValue('3bs', "X");
	    $document->setValue('3bn', "");
	} elseif ($_3b_placas_neurais == "N") {
	    $document->setValue('3bn', "X");
	    $document->setValue('3bs', "");
	} else {
	    $document->setValue('3bn', "");
	    $document->setValue('3bs', "");
	};
	//3B Parede em Perfil
	if ($_3b_parede_em_perfil_local == "0") {
	    $document->setValue('3parede_0_lo', "X");
	} else {
	    $document->setValue('3parede_0_lo', "");
	}

	if ($_3b_parede_em_perfil_local == "D") {
	    $document->setValue('3parede_d_lo', "X");
	} else {
	    $document->setValue('3parede_d_lo', "");
	}

	if ($_3b_parede_em_perfil_local == "e") {
	    $document->setValue('3parede_e_lo', "X");
	} else {
	    $document->setValue('3parede_e_lo', "");
	}

	if ($_3b_parede_em_perfil_calcificacao == "0") {
	    $document->setValue('3parede_0_cal', "X");
	} else {
	    $document->setValue('3parede_0_cal', "");
	};

	if ($_3b_parede_em_perfil_calcificacao == "D") {
	    $document->setValue('3parede_d_cal', "X");
	} else {
	    $document->setValue('3parede_d_cal', "");
	};

	if ($_3b_parede_em_perfil_calcificacao == "E") {
	    $document->setValue('3parede_e_cal', "X");
	} else {
	    $document->setValue('3parede_e_cal', "");
	};

	//3B Frontal
	if ($_3b_frontal_local == "0") {
	    $document->setValue('3frontal_0_lo', "X");
	} else {
	    $document->setValue('3frontal_0_lo', "");
	}

	if ($_3b_frontal_local == "D") {
	    $document->setValue('3frontal_d_lo', "X");
	} else {
	    $document->setValue('3frontal_d_lo', "");
	}

	if ($_3b_frontal_local == "E") {
	    $document->setValue('3frontal_e_lo', "X");
	} else {
	    $document->setValue('3frontal_e_lo', "");
	}

	if ($_3b_frontal_calcificacao == "0") {
	    $document->setValue('3frontal_0_cal', "X");
	} else {
	    $document->setValue('3frontal_0_cal', "");
	};

	if ($_3b_frontal_calcificacao == "D") {
	    $document->setValue('3frontal_d_cal', "X");
	} else {
	    $document->setValue('3frontal_d_cal', "");
	};

	if ($_3b_frontal_calcificacao == "e") {
	    $document->setValue('3frontal_e_cal', "X");
	} else {
	    $document->setValue('3frontal_e_cal', "");
	};

	//3B Diafragma Local

	if ($_3b_diafragma_local == "0") {
	    $document->setValue('3diafragma_0_lo', "X");
	} else {
	    $document->setValue('3diafragma_0_lo', "");
	};

	if ($_3b_diafragma_local == "D") {
	    $document->setValue('3diafragma_d_lo', "X");
	} else {
	    $document->setValue('3diafragma_d_lo', "");
	};

	if ($_3b_diafragma_local == "E") {
	    $document->setValue('3diafragma_e_lo', "X");
	} else {
	    $document->setValue('3diafragma_e_lo', "");
	};

	//3B Diafragma Calcificação
	if ($_3b_diafragma_calcificacao == "0") {
	    $document->setValue('3diafragma_0_cal', "X");
	} else {
	    $document->setValue('3diafragma_0_cal', "");
	};

	if ($_3b_diafragma_calcificacao == "D") {
	    $document->setValue('3diafragma_d_cal', "X");
	} else {
	    $document->setValue('3diafragma_d_cal', "");
	};

	if ($_3b_diafragma_calcificacao == "e") {
	    $document->setValue('3diafragma_e_cal', "X");
	} else {
	    $document->setValue('3diafragma_e_cal', "");
	};
	//3B Outros Locais Calcificação

	if ($_3b_outros_locais_calcificacao == "0") {
	    $document->setValue('outros_0_cal', "X");
	} else {
	    $document->setValue('outros_0_cal', "");
	};

	if ($_3b_outros_locais_calcificacao == "D") {
	    $document->setValue('outros_d_cal', "X");
	} else {
	    $document->setValue('outros_d_cal', "");
	};

	if ($_3b_outros_locais_calcificacao == "E") {
	    $document->setValue('outros_e_cal', "X");
	} else {
	    $document->setValue('outros_e_cal', "");
	};

	//3B Outros Locais

	if ($_3b_outros_locais_local == "0") {
	    $document->setValue('outros_0_lo', "X");
	} else {
	    $document->setValue('outros_0_lo', "");
	};

	if ($_3b_outros_locais_local == "d") {
	    $document->setValue('outros_d_lo', "X");
	} else {
	    $document->setValue('outros_d_lo', "");
	};

	if ($_3b_outros_locais_local == "e") {
	    $document->setValue('outros_e_lo', "X");
	} else {
	    $document->setValue('outros_e_lo', "");
	};


	//3B extenção parede
	if ($_3b_combinado_0d == "0") {
	    $document->setValue('3b_0d_0', "X");
	} else {
	    $document->setValue('3b_0d_0', "");
	}

	if ($_3b_combinado_0d == "D") {
	    $document->setValue('3b_0d_D', "X");
	} else {
	    $document->setValue('3b_0d_D', "");
	}

	if ($_3b_combinado_0d == "1") {
	    $document->setValue('3b_0d_1', "X");
	} else {
	    $document->setValue('3b_0d_1', "");
	}

	if ($_3b_combinado_0d == "2") {
	    $document->setValue('3b_0d_2', "X");
	} else {
	    $document->setValue('3b_0d_2', "");
	}

	if ($_3b_combinado_0d == "3") {
	    $document->setValue('3b_0d_3', "X");
	} else {
	    $document->setValue('3b_0d_3', "");
	}

	if ($_3b_combinado_0e == "0") {
	    $document->setValue('3b_0e_0', "X");
	} else {
	    $document->setValue('3b_0e_0', "");
	}

	if ($_3b_combinado_0e == "E") {
	    $document->setValue('3b_0e_E', "X");
	} else {
	    $document->setValue('3b_0e_E', "");
	}

	if ($_3b_combinado_0e == "1") {
	    $document->setValue('3b_0e_1', "X");
	} else {
	    $document->setValue('3b_0e_1', "");
	}

	if ($_3b_combinado_0e == "2") {
	    $document->setValue('3b_0e_2', "X");
	} else {
	    $document->setValue('3b_0e_2', "");
	}

	if ($_3b_combinado_0e == "3") {
	    $document->setValue('3b_0e_3', "X");
	} else {
	    $document->setValue('3b_0e_3', "");
	}

	if ($_3b_combinado_d == "D") {
	    $document->setValue('3d_D', "X");
	} else {
	    $document->setValue('3d_D', "");
	}

	if ($_3b_combinado_d == "A") {
	    $document->setValue('3d_a', "X");
	} else {
	    $document->setValue('3d_a', "");
	}

	if ($_3b_combinado_d == "B") {
	    $document->setValue('3d_b', "X");
	} else {
	    $document->setValue('3d_b', "");
	}

	if ($_3b_combinado_d == "C") {
	    $document->setValue('3d_c', "X");
	} else {
	    $document->setValue('3d_c', "");
	}

	if ($_3b_combinado_e == "E") {
	    $document->setValue('3e_E', "X");
	} else {
	    $document->setValue('3e_E', "");
	}

	if ($_3b_combinado_e == "A") {
	    $document->setValue('3e_a', "X");
	} else {
	    $document->setValue('3e_a', "");
	}

	if ($_3b_combinado_e == "B") {
	    $document->setValue('3e_b', "X");
	} else {
	    $document->setValue('3e_b', "");
	}

	if ($_3b_combinado_e == "C") {
	    $document->setValue('3e_c', "X");
	} else {
	    $document->setValue('3e_c', "");
	}

	//3C
	if ($_3c == "0") {
	    $document->setValue('3c0', "X");
	} else {
	    $document->setValue('3c0', "");
	}

	if ($_3c == "D") {
	    $document->setValue('3cD', "X");
	} else {
	    $document->setValue('3cD', "");
	}

	if ($_3c == "E") {
	    $document->setValue('3cE', "X");
	} else {
	    $document->setValue('3cE', "");
	}

	// 3D
	if ($_3d_espessamento_pleural_difuso == "S") {
	    $document->setValue('3ds', "X");
	    $document->setValue('3dn', "");
	} elseif ($_3d_espessamento_pleural_difuso == "N") {
	    $document->setValue('3dn', "X");
	    $document->setValue('3ds', "");
	} else {
	    $document->setValue('3dn', "");
	    $document->setValue('3ds', "");
	};

	//3B Parede em Perfil
	if ($_3d_parede_em_perfil_local == "0") {
	    $document->setValue('3d0_local', "X");
	} else {
	    $document->setValue('3d0_local', "");
	}

	if ($_3d_parede_em_perfil_local == "D") {
	    $document->setValue('3dD_local', "X");
	} else {
	    $document->setValue('3dD_local', "");
	};

	if ($_3d_parede_em_perfil_local == "E") {
	    $document->setValue('3dE_local', "X");
	} else {
	    $document->setValue('3dE_local', "");
	}

	if ($_3d_parede_em_perfil_calcificacao == "0") {
	    $document->setValue('3d0_calci', "X");
	} else {
	    $document->setValue('3d0_calci', "");
	};

	if ($_3d_parede_em_perfil_calcificacao == "D") {
	    $document->setValue('3dD_calci', "X");
	} else {
	    $document->setValue('3dD_calci', "");
	};

	if ($_3d_parede_em_perfil_calcificacao == "E") {
	    $document->setValue('3dE_calci', "X");
	} else {
	    $document->setValue('3dE_calci', "");
	};

	//3D Frontal
	if ($_3d_frontal_local == "0") {
	    $document->setValue('3d0_front_local', "X");
	} else {
	    $document->setValue('3d0_front_local', "");
	}

	if ($_3d_frontal_local == "D") {
	    $document->setValue('3dD_front_local', "X");
	} else {
	    $document->setValue('3dD_front_local', "");
	}

	if ($_3d_frontal_local == "E") {
	    $document->setValue('3de_calci_local', "X");
	} else {
	    $document->setValue('3de_calci_local', "");
	}

	if ($_3d_frontal_calcificacao == "0") {
	    $document->setValue('3d0_front_calc', "X");
	} else {
	    $document->setValue('3d0_front_calc', "");
	};

	if ($_3d_frontal_calcificacao == "D") {
	    $document->setValue('3dD_front_calc', "X");
	} else {
	    $document->setValue('3dD_front_calc', "");
	};

	if ($_3d_frontal_calcificacao == "E") {
	    $document->setValue('3dE_front_calc', "X");
	} else {
	    $document->setValue('3dE_front_calc', "");
	};

	// COMBINADO  
	if ($_3d_combinado_0d == "0") {
	    $document->setValue('3d_d_comb_0', "X");
	} else {
	    $document->setValue('3d_d_comb_0', "");
	}

	if ($_3d_combinado_0d == "D") {
	    $document->setValue('3d_d_comb_D', "X");
	} else {
	    $document->setValue('3d_d_comb_D', "");
	}

	if ($_3d_combinado_0d == "1") {
	    $document->setValue('3d_d_comb_1', "X");
	} else {
	    $document->setValue('3d_d_comb_1', "");
	}

	if ($_3d_combinado_0d == "2") {
	    $document->setValue('3d_d_comb_2', "X");
	} else {
	    $document->setValue('3d_d_comb_2', "");
	};

	if ($_3d_combinado_0d == "3") {
	    $document->setValue('3d_d_comb_3', "X");
	} else {
	    $document->setValue('3d_d_comb_3', "");
	}
	// Outro Quadrado

	if ($_3d_combinado_0d == "0") {
	    $document->setValue('3d_e_comb_0', "X");
	} else {
	    $document->setValue('3d_e_comb_0', "");
	}

	if ($_3d_combinado_0d == "E") {
	    $document->setValue('3d_e_comb_E', "X");
	} else {
	    $document->setValue('3d_e_comb_E', "");
	}

	if ($_3d_combinado_0d == "1") {
	    $document->setValue('3d_e_comb_1', "X");
	} else {
	    $document->setValue('3d_e_comb_1', "");
	}

	if ($_3d_combinado_0d == "2") {
	    $document->setValue('3d_e_comb_2', "X");
	} else {
	    $document->setValue('3d_e_comb_2', "");
	};

	if ($_3d_combinado_0d == "3") {
	    $document->setValue('3d_e_comb_3', "X");
	} else {
	    $document->setValue('3d_e_comb_3', "");
	}

	// 4A
	if ($_4a_outras_normalidades == "S") {
	    $document->setValue('4as', "X");
	    $document->setValue('4an', "");
	} elseif ($_4a_outras_normalidades == "N") {
	    $document->setValue('4an', "X");
	    $document->setValue('4as', "");
	} else {
	    $document->setValue('4an', "");
	    $document->setValue('4as', "");
	}

	// 4B Outras Anormalidades
	if ($_4b_outras_normalidades == "aa") {
	    $document->setValue('4baa', "X");
	} else {
	    $document->setValue('4baa', "");
	}

	if ($_4b_outras_normalidades == "at") {
	    $document->setValue('4Bat', "X");
	} else {
	    $document->setValue('4Bat', "");
	}

	if ($_4b_outras_normalidades == "ax") {
	    $document->setValue('4Bax', "X");
	} else {
	    $document->setValue('4Bax', "");
	}

	if ($_4b_outras_normalidades == "bu") {
	    $document->setValue('4Bbu', "X");
	} else {
	    $document->setValue('4Bbu', "");
	}

	if ($_4b_outras_normalidades == "ca") {
	    $document->setValue('4Bca', "X");
	} else {
	    $document->setValue('4Bca', "");
	}


	if ($_4b_outras_normalidades == "cg") {
	    $document->setValue('4Bcg', "X");
	} else {
	    $document->setValue('4Bcg', "");
	}

	if ($_4b_outras_normalidades == "cn") {
	    $document->setValue('4Bcn', "X");
	} else {
	    $document->setValue('4Bcn', "");
	}

	if ($_4b_outras_normalidades == "co") {
	    $document->setValue('4Bco', "X");
	} else {
	    $document->setValue('4Bco', "");
	}

	if ($_4b_outras_normalidades == "cp") {
	    $document->setValue('4Bcp', "X");
	} else {
	    $document->setValue('4Bcp', "");
	}

	if ($_4b_outras_normalidades == "cv") {
	    $document->setValue('4Bcv', "X");
	} else {
	    $document->setValue('4Bcv', "");
	}

	if ($_4b_outras_normalidades == "di") {
	    $document->setValue('4Bdi', "X");
	} else {
	    $document->setValue('4Bdi', "");
	}

	if ($_4b_outras_normalidades == "ef") {
	    $document->setValue('4Bef', "X");
	} else {
	    $document->setValue('4Bef', "");
	}

	if ($_4b_outras_normalidades == "em") {
	    $document->setValue('4Bem', "X");
	} else {
	    $document->setValue('4Bem', "");
	}

	if ($_4b_outras_normalidades == "es") {
	    $document->setValue('4Bes', "X");
	} else {
	    $document->setValue('4Bes', "");
	}

	if ($_4b_outras_normalidades == "fr") {
	    $document->setValue('4Bfr', "X");
	} else {
	    $document->setValue('4Bfr', "");
	}
	// Segunda linha

	if ($_4b_outras_normalidades == "hi") {
	    $document->setValue('4Bhi', "X");
	} else {
	    $document->setValue('4Bhi', "");
	}

	if ($_4b_outras_normalidades == "ho") {
	    $document->setValue('4Bho', "X");
	} else {
	    $document->setValue('4Bho', "");
	}

	if ($_4b_outras_normalidades == "id") {
	    $document->setValue('4Bid', "X");
	} else {
	    $document->setValue('4Bid', "");
	}

	if ($_4b_outras_normalidades == "ih") {
	    $document->setValue('4Bih', "X");
	} else {
	    $document->setValue('4Bih', "");
	}

	if ($_4b_outras_normalidades == "kl") {
	    $document->setValue('4Bkl', "X");
	} else {
	    $document->setValue('4Bkl', "");
	}

	if ($_4b_outras_normalidades == "me") {
	    $document->setValue('4Bme', "X");
	} else {
	    $document->setValue('4Bme', "");
	}

	if ($_4b_outras_normalidades == "pa") {
	    $document->setValue('4Bpa', "X");
	} else {
	    $document->setValue('4Bpa', "");
	}

	if ($_4b_outras_normalidades == "pb") {
	    $document->setValue('4Bpb', "X");
	} else {
	    $document->setValue('4Bpb', "");
	}

	if ($_4b_outras_normalidades == "pi") {
	    $document->setValue('4Bpi', "X");
	} else {
	    $document->setValue('4Bpi', "");
	}

	if ($_4b_outras_normalidades == "px") {
	    $document->setValue('4Bpx', "X");
	} else {
	    $document->setValue('4Bpx', "");
	}

	if ($_4b_outras_normalidades == "ra") {
	    $document->setValue('4Bra', "X");
	} else {
	    $document->setValue('4Bra', "");
	}

	if ($_4b_outras_normalidades == "rp") {
	    $document->setValue('4Brp', "X");
	} else {
	    $document->setValue('4Brp', "");
	}

	if ($_4b_outras_normalidades == "tb") {
	    $document->setValue('4Btb', "X");
	} else {
	    $document->setValue('4Btb', "");
	}

	if ($_4b_outras_normalidades == "od") {
	    $document->setValue('4Bod', "X");
	} else {
	    $document->setValue('4Bod', "");
	}


	$Arquivo = $this->getDiretorioParaGeracaoLaudo() . "/" . $this->getNomeLaudoGerado();
	$document->save($Arquivo);

	return true;
    }
<?php

$rootAddress = '';
require_once "phpword/PHPWord.php";
$dias = array("Domingo", "Lunes", "Martes", "Miercoles", "Jueves", "Viernes", "Sábado");
$meses = array("Enero", "Febrero", "Marzo", "Abril", "Mayo", "Junio", "Julio", "Agosto", "Septiembre", "Octubre", "Noviembre", "Diciembre");
$fecha = date('d') . 'días del mes de ' . $meses[date('n') - 1] . " del " . date('Y');
$word = new PHPWord();
$template = $word->loadTemplate($rootAddress . 'plantillas/PARA PPS.docx');
$template->setValue('${NOMBRE_ESTUDIANTE}', 'Luis Manuel Deras');
$template->setValue('${NUMERO_CUENTA}', '20112001640');
$template->setValue('${FECHA}', $fecha);
$template->save('test3.docx');
예제 #16
0
$tanggal = date('j');
//Array Bulan
$array_bulan = array(1 => 'Januari', 'Februari', 'Maret', 'April', 'Mei', 'Juni', 'Juli', 'Agustus', 'September', 'Oktober', 'November', 'Desember');
$bulan = $array_bulan[date('n')];
//Format Tahun
$tahun = date('Y');
$bilangan = new Terbilang();
// Include the PHPWord.php, all other classes were loaded by an autoloader
include '../../../../../plugin/PHPWord.php';
// Create a new PHPWord Object
$PHPWord = new PHPWord();
$template = '../../../../../config/Template/' . $NAMA_FILE;
$nama_template = $NAMA_JENIS;
if (file_exists($template)) {
    $template = $template;
    $document = $PHPWord->loadTemplate($template);
    $document->setValue('nomor_ppjb', $nomor);
    $document->setValue('hari', $hari);
    $document->setValue('tanggal', $tanggal);
    $document->setValue('bulan', $bulan);
    $document->setValue('tahun', $tahun);
    $document->setValue('tahun_terbilang', $bilangan->eja($tahun));
    $document->setValue('nama_pembeli', $nama_pembeli);
    $document->setValue('no_identitas', $no_identitas);
    $document->setValue('alamat', $alamat);
    $document->setValue('telp1', $tlp1);
    $document->setValue('telp3', $tlp3);
    $document->setValue('NAMA_PEJABAT', $NAMA_PEJABAT);
    $document->setValue('NAMA_JABATAN', $NAMA_JABATAN);
    $document->setValue('PEJABAT_PPJB', $PEJABAT_PPJB);
    $document->setValue('JABATAN_PPJB', $JABATAN_PPJB);
예제 #17
0
<?php

require_once 'modules/AOS_PDF_Templates/phpword/PHPWord.php';
$PHPWord = new PHPWord();
$document = $PHPWord->loadTemplate('modules/AOS_PDF_Templates/vnlicacodephpword/demo_template.docx');
$document->setValue('${From}', 'Bùi Cao Học');
$document->setValue('{_address1_}', '123 Trương Định');
$document->output('modules/RoomBookings/abc.docx');
예제 #18
0
}
switch ($act) {
    case 'print':
        $id = sqlReplace(trim($_GET['id']));
        if (!empty($id)) {
            $row = getuserinfo($id);
            if (!$row) {
                alertInfo('数据不存在', '', 1);
            }
            require_once 'PHPWord.php';
            $PHPWord = new PHPWord();
            //复制模板文件,变成下载文件
            $now = time();
            $y_url = '../userfiles/print.docx';
            $x_url = '../userfiles/docx/' . $now . '.docx';
            $document = $PHPWord->loadTemplate($y_url);
            $document->setValue('name', $row['user_name']);
            //姓名
            $document->setValue('phone', $row['user_phone']);
            //姓名
            //文件内容替换完毕  保存  下载
            $document->save($x_url);
            //header("Content-Type: application/force-download");
            //header("Content-Disposition: attachment; filename=".basename($x_url));
            //readfile($x_url);
            header("location:" . $x_url);
        } else {
            alertInfo('参数错误', '', 1);
        }
        break;
}
예제 #19
0
 function handleExport($post_id)
 {
     if (isset($_POST['filmExportType'])) {
         $type = $_POST['filmExportType'];
         $file = plugin_dir_path(__FILE__) . 'document_templates/' . $type . '.docx';
         $postData = get_post($post_id, ARRAY_A);
         $slug = $postData['post_name'];
         $fileOut = plugin_dir_path(__FILE__) . 'document_templates/tmp/' . $type . '-' . $slug . '.docx';
         $filename = basename($fileOut);
         if (!file_exists($file)) {
             return;
         }
         require_once plugin_dir_path(__FILE__) . 'vendors/phpword/PHPWord.php';
         $PHPWord = new PHPWord();
         $document = $PHPWord->loadTemplate($file);
         $fields = array('register_date', 'identity_code', 'title_orig', 'title', 'first_record_producer', 'application_provider', 'country', 'produce_date', 'director', 'type', 'genre', 'index', 'duration');
         if ($type == 'filmo-indekso-pazyma') {
         } else {
             if ($type == 'iregistruoto-filmo-israsas') {
                 $allRights = get_terms(array('film-right'), array('fields' => 'all', 'hide_empty' => false));
                 $filmRights = wp_get_post_terms($post_id, 'film-right', array('fields' => 'all'));
             }
         }
         ini_set('default_charset', 'utf-8');
         foreach ($fields as $val) {
             $value = $this->outputField($val);
             if ($val == 'title_orig' && $value == '') {
                 $value = $this->outputField('title');
             }
             $document->setValue($val, $value);
         }
         if (isset($allRights)) {
             $table = '<w:tbl>';
             $table .= '<w:tblPr>';
             $table .= '<w:tblW w:w = "5000" w:type="pct"/>';
             //$table .= '<w:tblCellSpacing w:w="50" w:type="dxa"/>';
             // $table .= '<w:tblCellPadding w:w="250" w:type="dxa"/>';
             $table .= '<w:tblCellMar>
                 <w:top w:w="50" w:type="dxa"/>
                 <w:start w:w="50" w:type="dxa"/>
                 <w:bottom w:w="50" w:type="dxa"/>
                 <w:end w:w="50" w:type="dxa"/>
                 </w:tblCellMar>';
             $table .= '<w:tblBorders>
                 <w:top w:val="single" w:sz="1" w:space="0" w:color="cccccc" />
                 <w:bottom w:val="single" w:sz="1" w:space="0" w:color="cccccc" />
                 <w:start w:val="single" w:sz="1" w:space="0" w:color="cccccc" />
                 <w:end w:val="single" w:sz="1" w:space="0" w:color="cccccc" />
                 <w:insideH w:val="single" w:sz="1" w:space="0" w:color="cccccc" />
                 <w:insideV w:val="single" w:sz="1" w:space="0" w:color="cccccc" />
                 </w:tblBorders>';
             $table .= '</w:tblPr>';
             // foreach($allRights as $key => $val){
             //     $table .= '<w:tr>';
             //         $table .= '<w:tc><w:p><w:r><w:t>';
             //             $table .= $val->name;
             //         $table .= '</w:t></w:r></w:p></w:tc>';
             //         $table .= '<w:tc><w:p><w:r><w:t>';
             //             $result = 'Ne';
             //             foreach ($filmRights as $key2 => $val2) {
             //                 if($val->term_id == $val2->term_id){
             //                     $result = 'Taip';
             //                     break;
             //                 }
             //             }
             //             $table .= $result;
             //         $table .= '</w:t></w:r></w:p></w:tc>';
             //     $table .= '</w:tr>';
             // }
             foreach ($allRights as $key => $val) {
                 foreach ($filmRights as $key2 => $val2) {
                     if ($val->term_id == $val2->term_id) {
                         $table .= '<w:tr>';
                         $table .= '<w:tc><w:p><w:r><w:t>';
                         $table .= $val->name;
                         $table .= '</w:t></w:r></w:p></w:tc>';
                         $table .= '<w:tc><w:p><w:r><w:t>';
                         $table .= 'Taip';
                         $table .= '</w:t></w:r></w:p></w:tc>';
                         $table .= '</w:tr>';
                         break;
                     }
                 }
             }
             $table .= '</w:tbl>';
             $document->setValue('rights', $table);
         }
         $document->save($fileOut);
         unset($document);
         header("Cache-Control: public");
         header("Content-Description: File Transfer");
         header("Content-Disposition: attachment; filename={$filename}");
         header('Content-Type: application/vnd.ms-word; charset=utf-8');
         header("Content-Transfer-Encoding: binary");
         readfile($fileOut);
         unlink($fileOut);
         exit;
     }
 }
예제 #20
0
파일: res.php 프로젝트: lflores10/octa
<?php

ini_set("memory_limit", "256M");
set_time_limit(10000);
require "../config/main.php";
require_once "PHPWord.php";
$PHPWord = new PHPWord();
$for = mssql_fetch_array(mssql_query("select * from tbformatosresultados where codigo_for={$FORMATO_RES}"));
$document = $PHPWord->loadTemplate("../../main/res/" . md5("FOR" . $FORMATO_RES));
$listStyle = array('listType' => PHPWord_Style_ListItem::TYPE_NUMBER);
$sql2 = mssql_query("select \nCAMPO_FOR, TIPO_FOR from \ntbformatosresultados2\nwhere formato_for=" . $FORMATO_RES);
while ($row2 = mssql_fetch_array($sql2)) {
    $res = '';
    $res = @mssql_result(mssql_query("select valor_res from tbformatosresultados3\n\twhere formato_res=" . $FORMATO_RES . " and ods_res=" . $ODS_RES . "\n\tand campo_res='" . md5($row2["CAMPO_FOR"]) . "'"), 0, 0);
    if ($row2["TIPO_FOR"] == 4) {
        if ($res == 1) {
            $document->setValue($row2["CAMPO_FOR"], '</w:t><w:t xml:space="preserve">          - ' . utf8_encode($row2["CAMPO_FOR"]) . '<w:br/>');
        } else {
            $document->setValue($row2["CAMPO_FOR"], '');
        }
    } else {
        $document->setValue($row2["CAMPO_FOR"], utf8_encode($res));
    }
}
$sql2 = mssql_query("select FORMATO_FOR, CAMPO_FOR, TIPO_FOR from tbformatosresultados2\ninner join TbProductos3 on\nFORMATO_FOR = FORMATO_FPR\nINNER JOIN TBEXPEDIENTES2 ON\nBAREMO_EXP = PRODUCTO_FPR\nWHERE CODIGO_EXP=" . $ODS_RES . " AND\nFORMATO_FOR <> " . $FORMATO_RES);
while ($row2 = mssql_fetch_array($sql2)) {
    $res = '';
    $res = @mssql_result(mssql_query("select valor_res from tbformatosresultados3\n\twhere formato_res=" . $row2["FORMATO_FOR"] . " and ods_res=" . $ODS_RES . "\n\tand campo_res='" . md5($row2["CAMPO_FOR"]) . "'"), 0, 0);
    if ($row2["TIPO_FOR"] == 4) {
        if ($res == 1) {
            $document->setValue($row2["CAMPO_FOR"], '</w:t><w:t xml:space="preserve">          - ' . utf8_encode($row2["CAMPO_FOR"]) . '<w:br/>');
예제 #21
0
     $nmaks = "0000";
 } elseif (strlen($data[nomor]) == 1) {
     $nmaks = "000" . $data[nomor];
 } elseif (strlen($data[nomor]) == 2) {
     $nmaks = "00" . $data[nomor];
 } elseif (strlen($data[nomor]) == 3) {
     $nmaks = "0" . $data[nomor];
 } else {
     $nmaks = $data[nomor];
 }
 if ($data['ekstension'] == 1) {
     $text_ijin = "perpanjangan";
 } else {
     $text_ijin = "baru";
 }
 $document = $PHPWord->loadTemplate('template/ijin-sendiri.docx');
 $document->setValue('jenis_ijin', $text_ijin);
 $document->setValue('kebangsaan', $data['country']);
 $document->setValue('kebangsaan', $data['namanegara']);
 $document->setValue('alamat_jalan', $data_univ['alamat_jalan']);
 $document->setValue('kota', $data_univ['nama_wilayah']);
 $document->setValue('jabatan', $data[jabatan]);
 $document->setValue('universitas', $data[namauniversitas]);
 $document->setValue('no_surat', $data[nosrtrek]);
 $document->setValue('Value1', $UTILITY->format_tanggal_ind($data[tglsrtrek]));
 //no surat
 //$document->setValue('surat', 'xx');
 if ($data[sex] == 1) {
     $sex = "Mr";
 } else {
     $sex = "Ms";
예제 #22
0
 public function test_nke3_install()
 {
     $PHPWord = new PHPWord();
     $document = $PHPWord->loadTemplate($this->in . '/Template2-filigrane.docx');
     $info2 = array("intro__c" => "Nous vous proposons au travers de cette offre de la qualité des produits nke pour votre First.", "Name" => "FIRST", "image__c" => $this->in . '/first-image1.png', "image2__c" => $this->in . '/first-image2.jpg', "products_std" => array(array('Name' => 'Multifonction TL25', 'option__c' => 'std', 'UnitPrice' => 10, 'Quantity' => 1), array('Name' => 'Support alu brossé', 'option__c' => 'std', 'UnitPrice' => 0, 'Quantity' => 1), array('Name' => 'compas Fluxgate', 'option__c' => 'std', 'UnitPrice' => 0, 'Quantity' => 1), array('Name' => 'télcommande filaire', 'option__c' => 'std', 'UnitPrice' => 0, 'Quantity' => 1), array('Name' => 'capteur sondeur + passe coque', 'option__c' => 'std', 'UnitPrice' => 0, 'Quantity' => 1), array('Name' => 'capteur loch roue à aubes + passe coque', 'option__c' => 'std', 'UnitPrice' => 0, 'Quantity' => 1), array('Name' => 'capteur anémo-girouette avec cable', 'option__c' => 'std', 'UnitPrice' => 0, 'Quantity' => 1), array('Name' => 'interface loch sondeur', 'option__c' => 'std', 'UnitPrice' => 0, 'Quantity' => 1), array('Name' => 'x 15 m de cable', 'option__c' => 'std', 'UnitPrice' => 0, 'Quantity' => 1), array('Name' => 'boite de connexion Bus', 'option__c' => 'std', 'UnitPrice' => 0, 'Quantity' => 1)), "products_std_amount" => 3452.48, "products_std_amount_ttc" => 4129.17, "lib_std__c" => "Pack régate", "products_opt1" => array(array('Name' => 'Multifonction Gyroplilot Graphic', 'option__c' => 'opt1', 'UnitPrice' => 100, 'Quantity' => 1), array('Name' => 'calculateur avec gyro intégré', 'option__c' => 'opt1', 'UnitPrice' => 0, 'Quantity' => 1), array('Name' => 'ensemble linéraire hydraulique type40', 'option__c' => 'opt1', 'UnitPrice' => 0, 'Quantity' => 1), array('Name' => 'convertisseur 12V/12V', 'option__c' => 'opt1', 'UnitPrice' => 0, 'Quantity' => 1), array('Name' => 'capteur angle de barre', 'option__c' => 'opt1', 'UnitPrice' => 0, 'Quantity' => 1), array('Name' => 'boîte connexion bus', 'option__c' => 'opt1', 'UnitPrice' => 0, 'Quantity' => 1), array('Name' => 'filtre alimentation', 'option__c' => 'opt1', 'UnitPrice' => 0, 'Quantity' => 1), array('Name' => 'x 15 m de câble bus', 'option__c' => 'opt1', 'UnitPrice' => 0, 'Quantity' => 1)), "products_opt1_amount" => 4741.88, "products_opt1_amount_ttc" => 5671.29, "lib_opt1__c" => "Pack Gyropilote type 40", "products_opt2" => array(array('Name' => 'Carbowind (capteur anémomètre giroutte HR 1,10m', 'option__c' => 'opt2', 'UnitPrice' => 100, 'Quantity' => 1), array('Name' => 'Cable carbowind avionic - 25m (17g/m)', 'option__c' => 'opt1', 'UnitPrice' => 0, 'Quantity' => 1), array('Name' => 'Capteur de vitesse Ultrason', 'option__c' => 'opt1', 'UnitPrice' => 0, 'Quantity' => 1), array('Name' => 'Compas Régatta (Gyrostabilisé 3 axes', 'option__c' => 'opt1', 'UnitPrice' => 0, 'Quantity' => 1)), "products_opt2_amount" => 3148.24, "products_opt2_amount_ttc" => 3765.29, "lib_opt2__c" => "Capteurs Haute Résolution", "products_opt3" => array(array('Name' => 'Processor Régatta', 'option__c' => 'opt2', 'UnitPrice' => 100, 'Quantity' => 1)), "products_opt3_amount" => 5129.4, "products_opt3_amount_ttc" => 6134.76, "lib_opt3__c" => "Capteurs vent réel 25HZ");
     echo "\nInfo Template \n";
     foreach ($info2 as $cle => $value) {
         if (strpos($cle, 'image') === 0) {
             switch ($cle) {
                 case 'image__c':
                     $cleimg = 'image1.png';
                     break;
                 case 'image2__c':
                     $cleimg = 'image2.jpg';
                     break;
             }
             $ret = $document->remplace_image($cleimg, $value);
             $this->assertTrue($ret, 'return of remplace_image');
             echo 'SetValue ' . $cleimg . '= ' . $value . "\n";
         } else {
             if (!is_array($value)) {
                 $document->setValue($cle, $value);
                 //echo 'SetValue '.$cle . '= '. $value."\n";
             } else {
                 $lstProd = array();
                 foreach ($value as $prod) {
                     $lstProd[] = $prod['Quantity'] . ' ' . $prod['Name'];
                 }
                 $document->setValueList($cle, $lstProd);
                 //echo 'SetValue '.$cle . '= '. implode(',',$lstProd)."\n";
             }
         }
     }
     $document->save($this->out . '/Templatenke3-result.docx');
 }
예제 #23
0
파일: Documento.php 프로젝트: Emape/std
 public function hoja_tramite()
 {
     $doc = $this->input->get_post('doc');
     $nrodoc = $this->input->get_post('nrodoc');
     $ini = $this->input->get_post('ini');
     $fin = $this->input->get_post('fin');
     $estado = "Dar Tramite";
     $estado1 = "Dar Tramite";
     $origen = "Tramite Documentario";
     $origen1 = "Tramite Documentario";
     if ($nrodoc % 2 == 0) {
         $doc1 = $nrodoc - 1;
         $doc2 = $nrodoc;
     } else {
         $doc1 = $nrodoc;
         $doc2 = $nrodoc + 1;
     }
     $filter = new stdClass();
     $filter_not = new stdClass();
     $filter->tipo_doc = $doc;
     $filter->nrodoc = $doc1;
     $filter->fecha_ini = str_replace('/', '-', $ini);
     $filter->fecha_fin = str_replace('/', '-', $fin);
     $var = $this->documento_model->listarDocumentoMovimiento($filter, $filter_not);
     $filter->tipo_doc = $doc;
     $filter->nrodoc = $doc2;
     $filter->fecha_ini = str_replace('/', '-', $ini);
     $filter->fecha_fin = str_replace('/', '-', $fin);
     $var1 = $this->documento_model->listarDocumentoMovimiento($filter, $filter_not);
     if ($var == "0") {
         $var = '[{"nroTramite":"","dependenciaMovimiento":"","tipo":"","fechaCreada":""}]';
         $var = json_decode($var);
         $estado = "";
         $origen = "";
     }
     if ($var1 == "0") {
         $var1 = '[{"nroTramite":"","dependenciaMovimiento":"","tipo":"","fechaCreada":""}]';
         $var1 = json_decode($var1);
         $estado1 = "";
         $origen1 = "";
     }
     $PHPWord = new PHPWord();
     //Searching for values to replace
     $document = $PHPWord->loadTemplate('./plantilla/plantilla01.docx');
     $document->setValue('Tramite', $var[0]->nroTramite);
     $document->setValue('Tramite2', $var1[0]->nroTramite);
     $document->setValue('Gerencia', $origen);
     $document->setValue('Gerencia2', $origen1);
     $document->setValue('Dependencia', $var[0]->dependenciaMovimiento);
     $document->setValue('Dependencia2', $var1[0]->dependenciaMovimiento);
     $document->setValue('Tipo', $var[0]->tipo);
     $document->setValue('Tipo2', $var1[0]->tipo);
     $document->setValue('Fecha', $var[0]->fechaCreada == "" ? "" : date('d/m/Y', strtotime($var[0]->fechaCreada)));
     $document->setValue('Fecha2', $var1[0]->fechaCreada == "" ? "" : date('d/m/Y', strtotime($var1[0]->fechaCreada)));
     $document->setValue('Estado', $estado);
     $document->setValue('Estado2', $estado1);
     // save as a random file in temp file
     $temp_file = tempnam(sys_get_temp_dir(), 'PHPWord');
     $document->save($temp_file);
     header("Content-Disposition: attachment; filename='hoja_tramite.doc'");
     header("Content-Type: application/vnd.ms-word; charset=utf-8");
     readfile($temp_file);
     // or echo file_get_contents($temp_file);
     unlink($temp_file);
     // remove temp file
 }
 public function generate($id = 0)
 {
     $this->load->library('PHPWord');
     $this->load->helper('util');
     $date = date('Y-m-d_H-i-s');
     //if ($id==0);
     $data = $this->db->where('id_permohonan_peng_data', $id)->join($this->cms_complete_table_name('mas_jurusan'), 'id_jurusan=fk_id_jurusan')->get($this->cms_complete_table_name('permohonan_peng_data'))->result();
     $PHPWord = new PHPWord();
     //Generate Document
     foreach ($data as $d) {
         $document = $PHPWord->loadTemplate('assets/surat_keluar/Permohonan Pengambilan Data/peng_data.docx');
         $document->setValue('nomor_surat', $d->nomor_surat);
         $document->setValue('lampiran', $d->lampiran);
         $document->setValue('kepada', $d->kepada);
         $document->setValue('di', $d->di);
         $document->setValue('nama_mahasiswa', $d->nama_mahasiswa);
         $document->setValue('npm', $d->npm);
         $document->setValue('jurusan', $d->nama_jurusan);
         $document->setValue('ketua_jurusan', $d->ketua_jurusan);
         $document->setValue('tanggal', tanggal(date('d-m-Y')));
         $document->setValue('bulan', bulan_romawi(date('m')));
         $document->setValue('tahun', date('Y'));
         ////open file////
         $objWriter = PHPWord_IOFactory::createWriter($PHPWord, 'Word2007');
         $filename = $d->npm . '-Surat_Permohonan_Peng_Data.docx';
         $document->save($filename);
         header('Content-Description: File Transfer');
         header('Content-Type: application/octet-stream');
         header('Content-Disposition: attachment; filename=' . $filename);
         header('Content-Transfer-Encoding: binary');
         header('Expires: 0');
         header('Cache-Control: must-revalidate, post-check=0, pre-check=0');
         header('Pragma: public');
         header('Content-Length: ' . filesize($filename));
         flush();
         readfile($filename);
         unlink($filename);
         // deletes the temporary file
         exit;
     }
     ////end of open file////
     ///save file////
     //$document->save('assets/docs/'.$d->nama_kar.'-'.$d->id_pegawai.'.docx');
     //redirect(base_url().'assets/docs/'.$d->nama_kar.'-'.$d->id_pegawai.'.docx', 'assets/manage_pegawai');
     ///end of save file////
 }
예제 #25
-1
 public function cetak($id_pegawai = false, $tahun = false)
 {
     require_once $this->server_root . 'system/cms/libraries/PHPWord.php';
     $PHPWord = new PHPWord();
     $path = $this->server_root . 'assets/file/skp/template/';
     $document = $PHPWord->loadTemplate($path . 'FORMAT_LEMBAR_PENILAIAN.docx');
     $arr = $this->set_value();
     foreach ($arr as $key => $field) {
         // dump($key);
         $document->setValue($key, $field);
     }
     // $a_penilai = $this->get_penilai_atasan($id_skp_penilai);
     // foreach($a_penilai as $k => $f){
     // $document->setValue($k, $f);
     // }
     $path = $this->server_root . 'assets/file/skp/lembarpenilaian/' . $tahun . '/';
     $document->save($path . $id_pegawai . '.docx');
 }
예제 #26
-1
//Format Tanggal Berbahasa Indonesia
// Array Hari
$array_hari = array(1 => 'Senin', 'Selasa', 'Rabu', 'Kamis', 'Jumat', 'Sabtu', 'Minggu');
$hari = $array_hari[date('N')];
//Format Tanggal
$tanggal = date('j');
//Array Bulan
$array_bulan = array(1 => 'Januari', 'Februari', 'Maret', 'April', 'Mei', 'Juni', 'Juli', 'Agustus', 'September', 'Oktober', 'November', 'Desember');
$bulan = $array_bulan[date('n')];
//Format Tahun
$tahun = date('Y');
// Include the PHPWord.php, all other classes were loaded by an autoloader
include '../../../../../plugin/PHPWord.php';
// Create a new PHPWord Object
$PHPWord = new PHPWord();
$document = $PHPWord->loadTemplate('../../../../../surat/Surat_Pemberitahuan_Jatuh_Tempo.docx');
//header
$document->setValue('nama_pembeli', $nama);
$path = 'E:\\';
$namafile = "Surat_Pemberitahuan_Jatuh_Tempo_" . "_" . "_" . date('d F Y') . ".docx";
// $document->save('E:\\andonnikahTemplate.docx');
//$document->save('E:\\'.$nama_file);
// At least write the document to webspace:
$objWriter = PHPWord_IOFactory::createWriter($PHPWord, 'Word2007');
// // save as a random file in temp file
$temp_file = tempnam(sys_get_temp_dir(), 'PHPWord');
$document->save($temp_file);
// Your browser will name the file "myFile.docx"
// regardless of what it's named on the server
header('Content-Disposition: attachment; filename="' . rawurlencode($namafile) . '"');
header('Content-Transfer-Encoding: binary');
예제 #27
-1
<?php

// examples
header("Content-type: text/html; charset=utf-8");
require_once '../PHPWord.php';
$PHPWord = new PHPWord();
$document = $PHPWord->loadTemplate('source.docx');
// simple parsing
$document->setValue('{var1}', 'value');
$document->setValue('{var2}', 'Clone');
$document->setValue('{var3}', 'ONE', 1);
// prepare data for tables
$data1 = array('num' => array(1, 2, 3), 'color' => array('red', 'blue', 'green'), 'code' => array('ff0000', '0000ff', '00ff00'));
$data2 = array('val1' => array(1, 2, 3), 'val2' => array('red', 'blue', 'green'), 'val3' => array('a', 'b', 'c'));
$data3 = array('day' => array('Mon', 'Tue', 'Wed', 'Thu', 'Fri'), 'dt' => array(12, 14, 13, 11, 10), 'nt' => array(0, 2, 1, 2, -1), 'dw' => array('SSE at 3 mph', 'SE at 2 mph', 'S at 3 mph', 'S at 1 mph', 'Calm'), 'nw' => array('SSE at 1 mph', 'SE at 1 mph', 'S at 1 mph', 'Calm', 'Calm'));
$data4 = array('val1' => array('blue 1', 'blue 2', 'blue 3'), 'val2' => array('green 1', 'green 2', 'green 3'), 'val3' => array('red 1', 'red 2', 'red 3'));
// clone rows
$document->cloneRow('TBL1', $data1);
$document->cloneRow('TBL2', $data2);
$document->cloneRow('DATA3', $data3);
$document->cloneRow('T4', $data4);
$document->cloneRow('DinamicTable', $data4);
// save file
$tmp_file = 'result.docx';
$document->save($tmp_file);
print date("Y-m-d H:i:s") . " <br>";
print "source.docx &rarr; result.docx <br>";
print "complete.";
 public function generate($id = 0)
 {
     $this->load->library('PHPWord');
     $this->load->helper('util');
     $date = date('Y-m-d_H-i-s');
     //if ($id==0);
     $conf = $this->db->get($this->cms_complete_table_name('konfigurasi'))->result();
     $data = $this->db->where('id_kelakuan_baik', $id)->join($this->cms_complete_table_name('mas_jurusan'), 'id_jurusan=fk_id_jurusan')->get($this->cms_complete_table_name('kelakuan_baik'))->result();
     $PHPWord = new PHPWord();
     //Generate Document
     foreach ($data as $d) {
         $document = $PHPWord->loadTemplate('assets/surat_keluar/Ket. Kelakuan Baik/kelakuan_baik.docx');
         $document->setValue('nomor_surat', $d->nomor_surat);
         $document->setValue('nama_mahasiswa', $d->nama_mahasiswa);
         $document->setValue('npm', $d->npm);
         $document->setValue('tempat_lahir', $d->tempat_lahir);
         $document->setValue('tanggal_lahir', tanggal(date($d->tanggal_lahir)));
         $document->setValue('jurusan', $d->nama_jurusan);
         $document->setValue('semester', $d->semester);
         $document->setValue('tahun_akademis', $d->tahun_akademis);
         $document->setValue('tanggal', tanggal(date('d-m-Y')));
         $document->setValue('bulan', bulan_romawi(date('m')));
         $document->setValue('tahun', date('Y'));
         foreach ($conf as $c) {
             $document->setValue('nama_instansi', $c->nama_instansi);
             $document->setValue('alamat', $c->alamat);
             $document->setValue('status_akreditasi', $c->status_akreditasi);
             $document->setValue('nama_puket', $c->nama_puket);
             $document->setValue('pangkat_puket', $c->pangkat_puket);
         }
         ////open file////
         $objWriter = PHPWord_IOFactory::createWriter($PHPWord, 'Word2007');
         $filename = $d->npm . '-Surat_Kelakuan_Baik.docx';
         $document->save($filename);
         header('Content-Description: File Transfer');
         header('Content-Type: application/octet-stream');
         header('Content-Disposition: attachment; filename=' . $filename);
         header('Content-Transfer-Encoding: binary');
         header('Expires: 0');
         header('Cache-Control: must-revalidate, post-check=0, pre-check=0');
         header('Pragma: public');
         header('Content-Length: ' . filesize($filename));
         flush();
         readfile($filename);
         unlink($filename);
         // deletes the temporary file
         exit;
     }
     ////end of open file////
     ///save file////
     //$document->save('assets/docs/'.$d->nama_kar.'-'.$d->id_pegawai.'.docx');
     //redirect(base_url().'assets/docs/'.$d->nama_kar.'-'.$d->id_pegawai.'.docx', 'assets/manage_pegawai');
     ///end of save file////
 }
예제 #29
-2
 foreach ((array) $cb_data as $id) {
     $query = "SELECT * FROM RESERVE WHERE KODE_BLOK = '{$id}'";
     $obj = $conn->execute($query);
     $kode_blok = $obj->fields['KODE_BLOK'];
     $nama_calon_pembeli = $obj->fields['NAMA_CALON_PEMBELI'];
     $tanggal_reserve = tgltgl(date("d-m-Y", strtotime($obj->fields['TANGGAL_RESERVE'])));
     $berlaku_sampai = tgltgl(date("d-m-Y", strtotime($obj->fields['BERLAKU_SAMPAI'])));
     $alamat = $obj->fields['ALAMAT'];
     $telepon = $obj->fields['TELEPON'];
     $agen = $obj->fields['AGEN'];
     $koordinator = $obj->fields['KOORDINATOR'];
     $tanggal_cetak = date('d-m-Y H:i:s');
     // Include the PHPWord.php, all other classes were loaded by an autoloader
     // Create a new PHPWord Object
     $PHPWord = new PHPWord();
     $document = $PHPWord->loadTemplate('../../../../../config/Template/surat/spp/Surat_Reserve.doc');
     //header
     $document->setValue('tanggal_cetak', $tanggal_cetak);
     $document->setValue('kode_blok', $kode_blok);
     $document->setValue('nama_calon_pembeli', $nama_calon_pembeli);
     $document->setValue('alamat', $alamat);
     $document->setValue('telepon', $telepon);
     $document->setValue('tanggal_reserve', $tanggal_reserve);
     $document->setValue('berlaku_sampai', $berlaku_sampai);
     $document->setValue('agen', $agen);
     $document->setValue('koordinator', $koordinator);
     $kode_blok = explode("/", $kode_blok);
     $kode_blok = implode("", $kode_blok);
     $nama_calon_pembeli = explode("/", $nama_calon_pembeli);
     $nama_calon_pembeli = implode("", $nama_calon_pembeli);
     $nama_file = "SURAT RESERVE " . trim($kode_blok) . " " . $nama_calon_pembeli . " " . $tanggal . " " . $bulan . " " . $tahun . ".doc";
예제 #30
-2
<?php 
require_once 'PHPWord.php';
$PHPWord = new PHPWord();
$document = $PHPWord->loadTemplate('Templateku.docx');
foreach ($lhs as $row) {
    $typekendaraan = $row->type_kendaraan;
    $modelkendaraan = $row->model_kendaraan;
    $nopolisi = $row->no_polisi;
    $nokuasa = $row->no_kuasa;
    $tglkuasa = date("d-M-Y", strtotime($row->terbit_kuasa));
    $nm_asuransi = $row->nm_asuransi;
    $id = $row->id_surat_tugas;
    $terimakuasa = date("d-M-Y", strtotime($row->terima_kuasa));
    $nmtertanggung = $row->nm_tertanggung;
    $almt_tertanggung = $row->almt_tertanggung;
    $nopolis = $row->no_polis;
    $tglberlaku = date("d-M-Y", strtotime($row->tgl_berlaku));
    $tglkedaluwarsa = date("d-M-Y", strtotime($row->tgl_kedaluwarsa));
    $surveyor = $row->nm_surveyor;
    $ket = $row->uraian_singkat;
    $saksi1 = $row->saksi1;
    $almt_saksi1 = $row->almt_saksi1;
    $ket_saksi1 = $row->ket_saksi1;
    $saksi2 = $row->saksi2;
    $almt_saksi2 = $row->almt_saksi2;
    $ket_saksi2 = $row->ket_saksi2;
    $saksi3 = $row->saksi3;
    $almt_saksi3 = $row->almt_saksi3;
    $ket_saksi3 = $row->ket_saksi3;
    $saksi4 = $row->saksi4;