Skip to content

Commit

Permalink
Merge branch '4.5.x' into dev
Browse files Browse the repository at this point in the history
  • Loading branch information
totoprayogo1916 committed Aug 14, 2023
2 parents 2e2b04f + 603867f commit 5abc7e3
Show file tree
Hide file tree
Showing 157 changed files with 47,435 additions and 3,191 deletions.
4 changes: 2 additions & 2 deletions .github/ISSUE_TEMPLATE/feature_request.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ body:
placeholder: Beritahu kami, kendala apa yang Anda alami
validations:
required: true

- type: textarea
id: solusi
attributes:
Expand All @@ -29,4 +29,4 @@ body:
id: tambahan
attributes:
label: Tambahan
description: Tambahan lain
description: Tambahan lain
11 changes: 11 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -28,3 +28,14 @@ writable/uploads/*
!writable/uploads/index.html

writable/debugbar/*

# ----------------------------------------------------------
# PUBLIC BUILD
# ----------------------------------------------------------
public/build/vendors/tinymce/**
!public/build/vendors/tinymce/**/
!public/build/vendors/tinymce/**/*.min.js
!public/build/vendors/tinymce/**/*.css
!public/build/vendors/tinymce/**/*.gif
!public/build/vendors/tinymce/**/*.swf
!public/build/vendors/tinymce/skins/**
3 changes: 3 additions & 0 deletions .gitmodules
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
[submodule "resources"]
path = resources
url = https://github.com/ataslangit/resources.git
4 changes: 1 addition & 3 deletions .php-cs-fixer.php
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,7 @@

$finder = Finder::create()
->in(__DIR__)
->name('*.php')
->ignoreDotFiles(true)
->exclude(['donjo-app/Views', 'donjo-app/ThirdParty', 'donjo-sys']);
->exclude(['donjo-app/Views', 'donjo-app/ThirdParty', 'donjo-sys', 'node_modules']);

$overrides = [];

Expand Down
3 changes: 2 additions & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@
"vendor-dir": "donjo-sys"
},
"scripts": {
"csfix": "./donjo-sys/bin/php-cs-fixer fix"
"csfix": "./donjo-sys/bin/php-cs-fixer fix",
"update-resources": "git submodule update --init --remote resources"
}
}
24 changes: 12 additions & 12 deletions composer.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

15 changes: 15 additions & 0 deletions docs/changelog/454.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
---
title: "Changelog SID v4.5.4"
---

# SID Versi v4.5.4

Rilis:

## :rocket: Peningkatan
- Gabung url `../main/initial` sebagai default daripada `../main`
- Hapus `index.php` dari url
- Relokasi file assets berupa css, js dan plugin lain

## :link: Link
-
15 changes: 0 additions & 15 deletions donjo-app/Controllers/Data_persil.php
Original file line number Diff line number Diff line change
Expand Up @@ -87,9 +87,6 @@ public function detail($id = 0)

public function create($id = 0)
{
$this->load->helper('form');
$this->load->library('form_validation');

$this->form_validation->set_rules('nama', 'Nama Jenis Persil', 'required');

$header = $this->header_model->get_data();
Expand All @@ -115,9 +112,6 @@ public function create($id = 0)

public function create_ext($id = 0)
{
$this->load->helper('form');
$this->load->library('form_validation');

$this->form_validation->set_rules('nama', 'Nama Jenis Persil', 'required');

$header = $this->header_model->get_data();
Expand All @@ -133,9 +127,6 @@ public function create_ext($id = 0)

public function simpan_persil($page = 1)
{
$this->load->helper('form');
$this->load->library('form_validation');

$this->form_validation->set_rules('nama', 'Nama Jenis Persil', 'required');
$header = $this->header_model->get_data();
echo view('header', $header);
Expand Down Expand Up @@ -175,9 +166,6 @@ public function peruntukan($apa = '', $page = 1)

public function persil_jenis($id = 0)
{
$this->load->helper('form');
$this->load->library('form_validation');

$this->form_validation->set_rules('nama', 'Nama Jenis Persil', 'required');
$header = $this->header_model->get_data();
echo view('header', $header);
Expand Down Expand Up @@ -207,9 +195,6 @@ public function hapus_persil_jenis($id)

public function persil_peruntukan($id = 0)
{
$this->load->helper('form');
$this->load->library('form_validation');

$this->form_validation->set_rules('nama', 'Nama Jenis Persil', 'required');
$header = $this->header_model->get_data();
echo view('header', $header);
Expand Down
5 changes: 4 additions & 1 deletion donjo-app/Controllers/Main.php
Original file line number Diff line number Diff line change
Expand Up @@ -51,10 +51,13 @@ public function index()
return redirect()->to('first');
}
} else {
return redirect()->to('main/initial');
return $this->initial();
}
}

/**
* View halaman instalasi pertama
*/
public function initial()
{
echo view('install');
Expand Down
6 changes: 0 additions & 6 deletions donjo-app/Controllers/Program_bantuan.php
Original file line number Diff line number Diff line change
Expand Up @@ -69,9 +69,6 @@ public function peserta($cat = 0, $id = 0)

public function create()
{
$this->load->helper('form');
$this->load->library('form_validation');

$this->form_validation->set_rules('cid', 'Sasaran', 'required');
$this->form_validation->set_rules('nama', 'Nama Program', 'required');
$this->form_validation->set_rules('sdate', 'Tanggal awal', 'required');
Expand All @@ -90,9 +87,6 @@ public function create()

public function edit($id)
{
$this->load->helper('form');
$this->load->library('form_validation');

$this->form_validation->set_rules('cid', 'Sasaran', 'required');
$this->form_validation->set_rules('nama', 'Nama Program', 'required');
$this->form_validation->set_rules('sdate', 'Tanggal awal', 'required');
Expand Down
60 changes: 60 additions & 0 deletions donjo-app/Helpers/donjolib_helper.php
Original file line number Diff line number Diff line change
@@ -1,5 +1,65 @@
<?php

/**
* This function checks `manifest.json` from `FCPATH` . 'build', extracts the entire file and returns an array.
*
* @param string $file The file name to check.
*
* @return string The path to the file, or `null` if the file does not exist.
*/
function asset(string $file): string
{
// Check if the manifest file exists.
$manifest_path = FCPATH . 'build' . DIRECTORY_SEPARATOR . 'manifest.json';

if (! file_exists($manifest_path)) {
return '';
}

// Decode the JSON file.
$manifest = json_decode(file_get_contents($manifest_path), true);

// Check if the file exists in the manifest file.
if (! isset($manifest[$file])) {
return '';
}

// Return the path to the file.
return base_url('build/' . $manifest[$file]['file']);
}

if (! function_exists('view')) {
/**
* fungsi view() untuk menggantikan $this->load->view()
*/
function view(string $view, array $data = [], bool $return = false)
{
$CI = &get_instance();

$CI->load->view($view, $data, $return);
}
}

if (! function_exists('dd')) {
/**
* Dump & die
*
* @param mixed ...$args
*
* @return void
*/
function dd(...$args)
{
if (ENVIRONMENT === 'development') {
var_dump($args);

exit;
}
}
}

// --------------------------------------------------------------------------

function Rpt($str = 0)
{
$satuan = ['', ' satu', ' dua', ' tiga', ' empat', ' lima', ' enam', ' tujuh', ' delapan', ' sembilan'];
Expand Down
1 change: 0 additions & 1 deletion donjo-app/Models/Analisis_import_model.php
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@ class Analisis_import_model extends CI_Model
public function __construct()
{
parent::__construct();
$this->load->helper('excel');
}

public function import_excel()
Expand Down
11 changes: 5 additions & 6 deletions donjo-app/Models/Analisis_respon_model.php
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@ class Analisis_respon_model extends CI_Model
public function __construct()
{
parent::__construct();
$this->load->helper('excel');
}

public function autocomplete()
Expand Down Expand Up @@ -785,8 +784,8 @@ public function data_unduh($p = 0, $o = 0)
$par = $query2->result_array();
$data[$i]['par'] = $par;

// $j++;
// }
// $j++;
// }
} else {
$data[$i]['par'] = null;
}
Expand Down Expand Up @@ -1052,7 +1051,7 @@ public function import_respon($op = 0)
$n++;
}
}
// }
// }
} else {
$sql = 'SELECT id FROM analisis_parameter WHERE id_indikator = ? AND jawaban = ?;';
$query = $this->db->query($sql, [$indi['id'], $isi]);
Expand Down Expand Up @@ -1190,7 +1189,7 @@ public function satu_jiwa($op = 0)
$n++;
}
}
// }
// }
} else {
$sql = 'SELECT id FROM analisis_parameter WHERE id_indikator = ? AND jawaban = ?;';
$query = $this->db->query($sql, [$indi['id'], $isi]);
Expand Down Expand Up @@ -1322,7 +1321,7 @@ public function dua_dunia($op = 0)
$n++;
}
}
// }
// }
} else {
$sql = 'SELECT id FROM analisis_parameter WHERE id_indikator = ? AND jawaban = ?;';
$query = $this->db->query($sql, [$indi['id'], $isi]);
Expand Down
2 changes: 0 additions & 2 deletions donjo-app/Models/Export_model.php
Original file line number Diff line number Diff line change
Expand Up @@ -262,8 +262,6 @@ public function lombok()
public function backup()
{
$this->load->dbutil();
$this->load->helper('download');
$this->load->helper('file');

$prefs = [
'format' => 'sql',
Expand Down
1 change: 0 additions & 1 deletion donjo-app/Models/Import_model.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,6 @@ public function __construct()
parent::__construct();
ini_set('memory_limit', '512M');
set_time_limit(3600);
$this->load->helper('excel');
}

public function import_siak()
Expand Down
1 change: 1 addition & 0 deletions donjo-app/Models/Penduduk_model.php
Original file line number Diff line number Diff line change
Expand Up @@ -326,6 +326,7 @@ public function log_sql()
return $log_sql;
}
$log_sql = '';

// $log_sql= " AND u.status_dasar = 1 ";
return $log_sql;
}
Expand Down
4 changes: 2 additions & 2 deletions donjo-app/Views/analisis_master/form.php
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<script src="<?php echo base_url('assets/tiny_mce/jquery.tinymce.min.js') ?>"></script>
<script src="<?php echo base_url('assets/tiny_mce/tinymce.min.js') ?>"></script>
<script src="<?php echo base_url('build/vendors/tinymce/jquery.tinymce.min.js') ?>"></script>
<script src="<?php echo base_url('build/vendors/tinymce/tinymce.min.js') ?>"></script>
<script>
tinymce.init({
selector: 'textarea',
Expand Down
4 changes: 2 additions & 2 deletions donjo-app/Views/gallery/table.php
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
});

</script>
<script src="<?php echo base_url('assets/front/js/jquery.colorbox.js')?>"></script>
<script src="<?= base_url('build/vendors/jquery.colorbox-min.js') ?>"></script>
<script>
$(document).ready(function() {
$(".color2").colorbox({
Expand All @@ -17,7 +17,7 @@
});

</script>
<link href="<?php echo base_url('assets/front/css/colorbox.css') ?>" rel="stylesheet">
<link href="<?= asset('resources/css/colorbox.css') ?>" rel="stylesheet">
<div id="pageC">
<table class="inner">
<tr style="vertical-align:top">
Expand Down
Loading

0 comments on commit 5abc7e3

Please sign in to comment.