Commit ef68c235 by iqbal

Merge branch 'beta-4.2-training' of https://git.opensipkd.com/aa.gusti/opensipkd…

…-base into beta-4.2-training
2 parents f2ba79c4 cb165740
Showing 29 changed files with 1156 additions and 229 deletions
eclipse.preferences.version=1
encoding/departemen.jrxml=UTF-8
encoding/partner.jrxml=UTF-8
encoding/pemerintah.jrxml=UTF-8
encoding/provinsi.jrxml=UTF-8
encoding/users-external.jrxml=UTF-8
encoding/users.jrxml=UTF-8
<?xml version="1.0" encoding="UTF-8" ?>
<jdbcDataAdapter class="net.sf.jasperreports.data.jdbc.JdbcDataAdapterImpl">
<name>New Data Adapter 1</name>
<name>DatabaseAdapter</name>
<driver>org.postgresql.Driver</driver>
<username>postgres</username>
<password>postgres</password>
......
<?xml version="1.0" encoding="UTF-8"?>
<!-- Created with Jaspersoft Studio version 6.20.5.final using JasperReports Library version 6.20.5-3efcf2e67f959db3888d79f73dde2dbd7acb4f8e -->
<jasperReport xmlns="http://jasperreports.sourceforge.net/jasperreports" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://jasperreports.sourceforge.net/jasperreports http://jasperreports.sourceforge.net/xsd/jasperreport.xsd" name="departemen" pageWidth="595" pageHeight="842" columnWidth="555" leftMargin="20" rightMargin="20" topMargin="20" bottomMargin="20" uuid="2fff6501-ac9b-4155-9f42-aac77153291b">
<property name="net.sf.jasperreports.data.adapter" value="DataAdapter.jrdax"/>
<property name="com.jaspersoft.studio.data.defaultdataadapter" value="DataAdapter.jrdax"/>
<jasperReport xmlns="http://jasperreports.sourceforge.net/jasperreports" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://jasperreports.sourceforge.net/jasperreports http://jasperreports.sourceforge.net/xsd/jasperreport.xsd" name="users" language="groovy" pageWidth="595" pageHeight="842" columnWidth="555" leftMargin="20" rightMargin="20" topMargin="20" bottomMargin="20" uuid="cc1a9dab-bb8a-4181-94ac-73c3dc91137c">
<property name="ireport.zoom" value="1.3310000000000004"/>
<property name="ireport.x" value="0"/>
<property name="ireport.y" value="0"/>
<property name="com.jaspersoft.studio.data.defaultdataadapter" value="DatabaseAdapter.jrdax"/>
<property name="com.jaspersoft.studio.data.sql.tables" value=""/>
<parameter name="judul" class="java.lang.String"/>
<parameter name="logo" class="java.lang.String"/>
<queryString>
<![CDATA[]]>
<![CDATA[SELECT *
FROM departemen]]>
</queryString>
<field name="kode" class="java.lang.String"/>
<field name="uraian" class="java.lang.String"/>
<field name="status" class="java.lang.String"/>
<field name="id" class="java.lang.Integer">
<property name="com.jaspersoft.studio.field.name" value="id"/>
<property name="com.jaspersoft.studio.field.label" value="id"/>
<property name="com.jaspersoft.studio.field.tree.path" value="departemen"/>
</field>
<field name="parent_id" class="java.lang.Integer">
<property name="com.jaspersoft.studio.field.name" value="parent_id"/>
<property name="com.jaspersoft.studio.field.label" value="parent_id"/>
<property name="com.jaspersoft.studio.field.tree.path" value="departemen"/>
</field>
<field name="kategori" class="java.lang.String">
<property name="com.jaspersoft.studio.field.name" value="kategori"/>
<property name="com.jaspersoft.studio.field.label" value="kategori"/>
<property name="com.jaspersoft.studio.field.tree.path" value="departemen"/>
</field>
<field name="alamat" class="java.lang.String">
<property name="com.jaspersoft.studio.field.name" value="alamat"/>
<property name="com.jaspersoft.studio.field.label" value="alamat"/>
<property name="com.jaspersoft.studio.field.tree.path" value="departemen"/>
</field>
<field name="singkat" class="java.lang.String">
<property name="com.jaspersoft.studio.field.name" value="singkat"/>
<property name="com.jaspersoft.studio.field.label" value="singkat"/>
<property name="com.jaspersoft.studio.field.tree.path" value="departemen"/>
</field>
<field name="level_id" class="java.lang.Integer">
<property name="com.jaspersoft.studio.field.name" value="level_id"/>
<property name="com.jaspersoft.studio.field.label" value="level_id"/>
<property name="com.jaspersoft.studio.field.tree.path" value="departemen"/>
</field>
<field name="company_id" class="java.lang.Integer">
<property name="com.jaspersoft.studio.field.name" value="company_id"/>
<property name="com.jaspersoft.studio.field.label" value="company_id"/>
<property name="com.jaspersoft.studio.field.tree.path" value="departemen"/>
</field>
<field name="nama" class="java.lang.String">
<property name="com.jaspersoft.studio.field.name" value="nama"/>
<property name="com.jaspersoft.studio.field.label" value="nama"/>
<property name="com.jaspersoft.studio.field.tree.path" value="departemen"/>
</field>
<field name="kode" class="java.lang.String">
<property name="com.jaspersoft.studio.field.name" value="kode"/>
<property name="com.jaspersoft.studio.field.label" value="kode"/>
<property name="com.jaspersoft.studio.field.tree.path" value="departemen"/>
</field>
<field name="status" class="java.lang.Integer">
<property name="com.jaspersoft.studio.field.name" value="status"/>
<property name="com.jaspersoft.studio.field.label" value="status"/>
<property name="com.jaspersoft.studio.field.tree.path" value="departemen"/>
</field>
<field name="created" class="java.sql.Timestamp">
<property name="com.jaspersoft.studio.field.name" value="created"/>
<property name="com.jaspersoft.studio.field.label" value="created"/>
<property name="com.jaspersoft.studio.field.tree.path" value="departemen"/>
</field>
<field name="updated" class="java.sql.Timestamp">
<property name="com.jaspersoft.studio.field.name" value="updated"/>
<property name="com.jaspersoft.studio.field.label" value="updated"/>
<property name="com.jaspersoft.studio.field.tree.path" value="departemen"/>
</field>
<field name="create_uid" class="java.lang.Integer">
<property name="com.jaspersoft.studio.field.name" value="create_uid"/>
<property name="com.jaspersoft.studio.field.label" value="create_uid"/>
<property name="com.jaspersoft.studio.field.tree.path" value="departemen"/>
</field>
<field name="update_uid" class="java.lang.Integer">
<property name="com.jaspersoft.studio.field.name" value="update_uid"/>
<property name="com.jaspersoft.studio.field.label" value="update_uid"/>
<property name="com.jaspersoft.studio.field.tree.path" value="departemen"/>
</field>
<background>
<band splitType="Stretch"/>
</background>
<title>
<band height="86" splitType="Stretch">
<band height="69" splitType="Stretch">
<staticText>
<reportElement x="60" y="10" width="430" height="20" uuid="7907aaed-3ca2-4074-a0d5-54c4733794f1"/>
<reportElement x="63" y="40" width="492" height="20" uuid="abe9cbb1-2e91-4eb0-b3ee-05e9a967c5f6"/>
<textElement textAlignment="Center">
<font size="12" isBold="true"/>
<font size="14" isBold="true"/>
</textElement>
<text><![CDATA[ PEMERINTAH TANGERANG]]></text>
</staticText>
<staticText>
<reportElement x="0" y="30" width="550" height="20" uuid="8c30bb08-d120-4ed4-9ca7-643824daa3c3"/>
<textElement textAlignment="Center">
<font size="12" isBold="true"/>
</textElement>
<text><![CDATA[DAFTAR SKPD BADAN PENGELOLAAN KEUANGAN, ]]></text>
</staticText>
<staticText>
<reportElement x="0" y="50" width="551" height="21" uuid="e522b93e-5e85-4d33-99be-0e28e724a242"/>
<textElement textAlignment="Center" verticalAlignment="Middle">
<font size="12" isBold="true"/>
</textElement>
<text><![CDATA[PENDAPATAN DAN ASET DAERAH]]></text>
<text><![CDATA[DAFTAR USER]]></text>
</staticText>
<image>
<reportElement x="0" y="-10" width="81" height="81" uuid="f5fc8620-8911-454c-9f92-98911c586d44"/>
<imageExpression><![CDATA["C:/Users/LENOVO/Downloads/logo-kota-tangsel2.jpg"]]></imageExpression>
<reportElement x="10" y="10" width="53" height="58" uuid="3fe2de31-ff3e-4451-8d0d-6b2753184c09"/>
<imageExpression><![CDATA[$P{logo}]]></imageExpression>
</image>
<textField>
<reportElement x="63" y="10" width="492" height="30" uuid="00412b89-3587-423f-8aaf-1526e5f32540"/>
<textElement textAlignment="Center">
<font size="20" isBold="true"/>
</textElement>
<textFieldExpression><![CDATA[$P{judul}]]></textFieldExpression>
</textField>
<line>
<reportElement x="0" y="75" width="560" height="1" uuid="2df4a847-51f0-4c5d-a721-93d89df3c254"/>
<graphicElement>
<pen lineWidth="4.0"/>
</graphicElement>
<reportElement mode="Opaque" x="0" y="66" width="555" height="2" backcolor="#030303" uuid="458a97c9-219f-4e32-853f-db6a89ccb260">
<property name="com.jaspersoft.studio.unit.height" value="px"/>
</reportElement>
</line>
</band>
</title>
<pageHeader>
<band height="5" splitType="Stretch"/>
</pageHeader>
<columnHeader>
<band height="47" splitType="Stretch">
<band height="20" splitType="Stretch">
<staticText>
<reportElement mode="Opaque" x="10" y="17" width="120" height="30" backcolor="#FFF705" uuid="9555e3e8-9f97-4e48-bd6f-9e2accaeea4f"/>
<box padding="0">
<reportElement x="0" y="0" width="80" height="20" uuid="45c2cace-4a3f-495c-9002-be2f2ac8eca4"/>
<box topPadding="0" leftPadding="0" bottomPadding="0" rightPadding="0">
<topPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<leftPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<bottomPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<rightPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
</box>
<textElement textAlignment="Center" verticalAlignment="Middle">
<font size="12" isBold="true"/>
<textElement textAlignment="Center">
<font isBold="true" isUnderline="true"/>
</textElement>
<text><![CDATA[Kode]]></text>
</staticText>
<staticText>
<reportElement mode="Opaque" x="130" y="17" width="290" height="30" backcolor="#FFFB05" uuid="97544881-7f4b-4fe1-aa8a-d321e0185d14"/>
<box padding="0">
<reportElement x="80" y="0" width="140" height="20" uuid="3a03e8b0-96f7-4754-b00e-ceae1a0e5aa9"/>
<box>
<topPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<leftPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<bottomPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<rightPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
</box>
<textElement textAlignment="Center" verticalAlignment="Middle">
<font size="12" isBold="true"/>
<textElement textAlignment="Center">
<font isBold="true" isUnderline="true"/>
</textElement>
<text><![CDATA[Uraian]]></text>
<text><![CDATA[Nama]]></text>
</staticText>
<staticText>
<reportElement mode="Opaque" x="420" y="17" width="100" height="30" backcolor="#FFFB05" uuid="5c9c4ce2-5d01-45ce-8dd3-0515e28456c5"/>
<box padding="0">
<reportElement x="220" y="0" width="100" height="20" uuid="f19e05c8-f1bf-4d94-927d-07111ed068df"/>
<box topPadding="0" leftPadding="0" bottomPadding="0" rightPadding="0">
<topPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<leftPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<bottomPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<rightPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
</box>
<textElement textAlignment="Center" verticalAlignment="Middle">
<font size="12" isBold="true"/>
<textElement textAlignment="Center">
<font isBold="true" isUnderline="true"/>
</textElement>
<text><![CDATA[Status]]></text>
</staticText>
<staticText>
<reportElement x="320" y="0" width="100" height="20" uuid="8a8040c2-e6ba-4473-835f-c9cfe3568fb9"/>
<box topPadding="0" leftPadding="0" bottomPadding="0" rightPadding="0">
<topPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<leftPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<bottomPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<rightPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
</box>
<textElement textAlignment="Center">
<font isBold="true" isUnderline="true"/>
</textElement>
<text><![CDATA[Level]]></text>
</staticText>
<staticText>
<reportElement x="420" y="0" width="70" height="20" uuid="edcbda0a-3095-49b2-ac2d-1400a2550e0c"/>
<box topPadding="0" leftPadding="0" bottomPadding="0" rightPadding="0">
<topPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<leftPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<bottomPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<rightPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
</box>
<textElement textAlignment="Center">
<font isBold="true" isUnderline="true"/>
</textElement>
<text><![CDATA[Induk]]></text>
</staticText>
<staticText>
<reportElement x="490" y="0" width="70" height="20" uuid="3f9aa34e-9187-4825-b835-7a639f7435ea"/>
<box topPadding="0" leftPadding="0" bottomPadding="0" rightPadding="0">
<topPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<leftPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<bottomPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<rightPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
</box>
<textElement textAlignment="Center">
<font isBold="true" isUnderline="true"/>
</textElement>
<text><![CDATA[Company]]></text>
</staticText>
</band>
</columnHeader>
<detail>
<band height="40" splitType="Stretch">
<band height="20" splitType="Stretch">
<textField>
<reportElement x="130" y="0" width="290" height="31" uuid="3a3c38b9-dc87-44ca-bd86-ed61df760649"/>
<box>
<reportElement x="0" y="0" width="80" height="20" uuid="aec5f07a-b9fb-4ce1-9e7e-957f6315acb0"/>
<box topPadding="0" leftPadding="0" bottomPadding="0" rightPadding="0">
<topPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<leftPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<bottomPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<rightPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
</box>
<textElement textAlignment="Center"/>
<textFieldExpression><![CDATA[$F{kode}]]></textFieldExpression>
</textField>
<textField>
<reportElement x="80" y="0" width="140" height="20" uuid="04eef3a7-87ca-4a27-9392-1368a6ba2fd1"/>
<box topPadding="0" leftPadding="0" bottomPadding="0" rightPadding="0">
<topPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<leftPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<bottomPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<rightPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
</box>
<textElement textAlignment="Center" verticalAlignment="Middle"/>
<textFieldExpression><![CDATA[$F{uraian}]]></textFieldExpression>
<textElement textAlignment="Center"/>
<textFieldExpression><![CDATA[$F{nama}]]></textFieldExpression>
</textField>
<textField>
<reportElement x="10" y="0" width="120" height="31" uuid="335a5b59-4b33-4861-9234-00ce88a594a4"/>
<reportElement x="320" y="0" width="100" height="20" uuid="24a12a8f-a1e1-4ae3-adb7-bbcf450560ee"/>
<box topPadding="0" leftPadding="0" bottomPadding="0" rightPadding="0">
<topPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<leftPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<bottomPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<rightPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
</box>
<textElement textAlignment="Center"/>
<textFieldExpression><![CDATA[$F{level_id}]]></textFieldExpression>
</textField>
<textField>
<reportElement x="220" y="0" width="100" height="20" uuid="47051f05-f634-4c32-97cc-ce9af7b8f382"/>
<box topPadding="0" leftPadding="0" bottomPadding="0" rightPadding="0">
<topPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<leftPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<bottomPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<rightPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
</box>
<textElement textAlignment="Center"/>
<textFieldExpression><![CDATA[$F{status}]]></textFieldExpression>
</textField>
<textField>
<reportElement x="420" y="0" width="70" height="20" uuid="71bc4159-0a66-4c12-ab5b-1b17c33628c5"/>
<box>
<topPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<leftPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<bottomPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<rightPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
</box>
<textElement textAlignment="Center" verticalAlignment="Middle"/>
<textFieldExpression><![CDATA[$F{kode}]]></textFieldExpression>
<textFieldExpression><![CDATA[$F{parent_id}]]></textFieldExpression>
</textField>
<textField>
<reportElement x="420" y="0" width="100" height="31" uuid="97903e6e-830b-4204-820c-3a402f03cd48"/>
<reportElement x="490" y="0" width="70" height="20" uuid="e690dd42-8996-40ad-a436-57cf4e3789c5"/>
<box>
<topPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<leftPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<bottomPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<rightPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
</box>
<textElement textAlignment="Center" verticalAlignment="Middle"/>
<textFieldExpression><![CDATA[$F{status}]]></textFieldExpression>
<textFieldExpression><![CDATA[$F{company_id}]]></textFieldExpression>
</textField>
</band>
</detail>
<columnFooter>
<band height="99" splitType="Stretch"/>
<band height="45" splitType="Stretch"/>
</columnFooter>
<pageFooter>
<band height="54" splitType="Stretch"/>
<band height="58" splitType="Stretch"/>
</pageFooter>
<summary>
<band height="42" splitType="Stretch"/>
......
<?xml version="1.0" encoding="UTF-8"?>
<!-- Created with Jaspersoft Studio version 6.20.5.final using JasperReports Library version 6.20.5-3efcf2e67f959db3888d79f73dde2dbd7acb4f8e -->
<jasperReport xmlns="http://jasperreports.sourceforge.net/jasperreports" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://jasperreports.sourceforge.net/jasperreports http://jasperreports.sourceforge.net/xsd/jasperreport.xsd" name="users" language="groovy" pageWidth="595" pageHeight="842" columnWidth="555" leftMargin="20" rightMargin="20" topMargin="20" bottomMargin="20" uuid="cc1a9dab-bb8a-4181-94ac-73c3dc91137c">
<property name="ireport.zoom" value="1.3310000000000004"/>
<property name="ireport.x" value="0"/>
<property name="ireport.y" value="0"/>
<property name="com.jaspersoft.studio.data.defaultdataadapter" value="DatabaseAdapter.jrdax"/>
<property name="com.jaspersoft.studio.data.sql.tables" value=""/>
<parameter name="judul" class="java.lang.String"/>
<parameter name="logo" class="java.lang.String"/>
<queryString>
<![CDATA[SELECT *
FROM company]]>
</queryString>
<field name="id" class="java.lang.Integer">
<property name="com.jaspersoft.studio.field.name" value="id"/>
<property name="com.jaspersoft.studio.field.label" value="id"/>
<property name="com.jaspersoft.studio.field.tree.path" value="company"/>
</field>
<field name="partner_id" class="java.lang.Integer">
<property name="com.jaspersoft.studio.field.name" value="partner_id"/>
<property name="com.jaspersoft.studio.field.label" value="partner_id"/>
<property name="com.jaspersoft.studio.field.tree.path" value="company"/>
</field>
<field name="parent_id" class="java.lang.Integer">
<property name="com.jaspersoft.studio.field.name" value="parent_id"/>
<property name="com.jaspersoft.studio.field.label" value="parent_id"/>
<property name="com.jaspersoft.studio.field.tree.path" value="company"/>
</field>
<field name="nama" class="java.lang.String">
<property name="com.jaspersoft.studio.field.name" value="nama"/>
<property name="com.jaspersoft.studio.field.label" value="nama"/>
<property name="com.jaspersoft.studio.field.tree.path" value="company"/>
</field>
<field name="kode" class="java.lang.String">
<property name="com.jaspersoft.studio.field.name" value="kode"/>
<property name="com.jaspersoft.studio.field.label" value="kode"/>
<property name="com.jaspersoft.studio.field.tree.path" value="company"/>
</field>
<field name="status" class="java.lang.Integer">
<property name="com.jaspersoft.studio.field.name" value="status"/>
<property name="com.jaspersoft.studio.field.label" value="status"/>
<property name="com.jaspersoft.studio.field.tree.path" value="company"/>
</field>
<field name="created" class="java.sql.Timestamp">
<property name="com.jaspersoft.studio.field.name" value="created"/>
<property name="com.jaspersoft.studio.field.label" value="created"/>
<property name="com.jaspersoft.studio.field.tree.path" value="company"/>
</field>
<field name="updated" class="java.sql.Timestamp">
<property name="com.jaspersoft.studio.field.name" value="updated"/>
<property name="com.jaspersoft.studio.field.label" value="updated"/>
<property name="com.jaspersoft.studio.field.tree.path" value="company"/>
</field>
<field name="create_uid" class="java.lang.Integer">
<property name="com.jaspersoft.studio.field.name" value="create_uid"/>
<property name="com.jaspersoft.studio.field.label" value="create_uid"/>
<property name="com.jaspersoft.studio.field.tree.path" value="company"/>
</field>
<field name="update_uid" class="java.lang.Integer">
<property name="com.jaspersoft.studio.field.name" value="update_uid"/>
<property name="com.jaspersoft.studio.field.label" value="update_uid"/>
<property name="com.jaspersoft.studio.field.tree.path" value="company"/>
</field>
<background>
<band splitType="Stretch"/>
</background>
<title>
<band height="73" splitType="Stretch">
<staticText>
<reportElement x="63" y="40" width="492" height="20" uuid="abe9cbb1-2e91-4eb0-b3ee-05e9a967c5f6"/>
<textElement textAlignment="Center">
<font size="14" isBold="true"/>
</textElement>
<text><![CDATA[DAFTAR PEMERINTAH]]></text>
</staticText>
<image>
<reportElement x="10" y="10" width="53" height="58" uuid="3fe2de31-ff3e-4451-8d0d-6b2753184c09"/>
<imageExpression><![CDATA[$P{logo}]]></imageExpression>
</image>
<textField>
<reportElement x="63" y="10" width="492" height="30" uuid="00412b89-3587-423f-8aaf-1526e5f32540"/>
<textElement textAlignment="Center">
<font size="20" isBold="true"/>
</textElement>
<textFieldExpression><![CDATA[$P{judul}]]></textFieldExpression>
</textField>
</band>
</title>
<pageHeader>
<band height="7" splitType="Stretch">
<line>
<reportElement x="0" y="-5" width="555" height="1" uuid="10e401ac-e33c-4e46-b2e1-62703f3cea4e"/>
<graphicElement>
<pen lineWidth="4.0"/>
</graphicElement>
</line>
</band>
</pageHeader>
<columnHeader>
<band height="20" splitType="Stretch">
<staticText>
<reportElement x="0" y="0" width="100" height="20" uuid="45c2cace-4a3f-495c-9002-be2f2ac8eca4"/>
<box topPadding="0" leftPadding="0" bottomPadding="0" rightPadding="0">
<topPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<leftPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<bottomPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<rightPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
</box>
<textElement textAlignment="Center">
<font isBold="true" isUnderline="true"/>
</textElement>
<text><![CDATA[Kode]]></text>
</staticText>
<staticText>
<reportElement x="100" y="0" width="255" height="20" uuid="3a03e8b0-96f7-4754-b00e-ceae1a0e5aa9"/>
<box>
<topPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<leftPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<bottomPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<rightPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
</box>
<textElement textAlignment="Center">
<font isBold="true" isUnderline="true"/>
</textElement>
<text><![CDATA[Nama]]></text>
</staticText>
<staticText>
<reportElement x="355" y="0" width="100" height="20" uuid="f19e05c8-f1bf-4d94-927d-07111ed068df"/>
<box topPadding="0" leftPadding="0" bottomPadding="0" rightPadding="0">
<topPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<leftPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<bottomPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<rightPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
</box>
<textElement textAlignment="Center">
<font isBold="true" isUnderline="true"/>
</textElement>
<text><![CDATA[Parent Nm]]></text>
</staticText>
<staticText>
<reportElement x="455" y="0" width="100" height="20" uuid="8a8040c2-e6ba-4473-835f-c9cfe3568fb9"/>
<box topPadding="0" leftPadding="0" bottomPadding="0" rightPadding="0">
<topPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<leftPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<bottomPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<rightPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
</box>
<textElement textAlignment="Center">
<font isBold="true" isUnderline="true"/>
</textElement>
<text><![CDATA[Status]]></text>
</staticText>
</band>
</columnHeader>
<detail>
<band height="20" splitType="Stretch">
<textField>
<reportElement x="0" y="0" width="100" height="20" uuid="aec5f07a-b9fb-4ce1-9e7e-957f6315acb0"/>
<box topPadding="0" leftPadding="0" bottomPadding="0" rightPadding="0">
<topPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<leftPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<bottomPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<rightPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
</box>
<textElement textAlignment="Center"/>
<textFieldExpression><![CDATA[$F{kode}]]></textFieldExpression>
</textField>
<textField>
<reportElement x="100" y="0" width="255" height="20" uuid="04eef3a7-87ca-4a27-9392-1368a6ba2fd1"/>
<box topPadding="0" leftPadding="0" bottomPadding="0" rightPadding="0">
<topPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<leftPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<bottomPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<rightPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
</box>
<textElement textAlignment="Center"/>
<textFieldExpression><![CDATA[$F{nama}]]></textFieldExpression>
</textField>
<textField>
<reportElement x="455" y="0" width="100" height="20" uuid="24a12a8f-a1e1-4ae3-adb7-bbcf450560ee"/>
<box topPadding="0" leftPadding="0" bottomPadding="0" rightPadding="0">
<topPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<leftPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<bottomPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<rightPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
</box>
<textElement textAlignment="Center"/>
<textFieldExpression><![CDATA[$F{status}]]></textFieldExpression>
</textField>
<textField>
<reportElement x="355" y="0" width="100" height="20" uuid="47051f05-f634-4c32-97cc-ce9af7b8f382"/>
<box topPadding="0" leftPadding="0" bottomPadding="0" rightPadding="0">
<topPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<leftPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<bottomPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<rightPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
</box>
<textElement textAlignment="Center"/>
<textFieldExpression><![CDATA[$F{parent_id}]]></textFieldExpression>
</textField>
</band>
</detail>
<columnFooter>
<band height="45" splitType="Stretch"/>
</columnFooter>
<pageFooter>
<band height="54" splitType="Stretch"/>
</pageFooter>
<summary>
<band height="42" splitType="Stretch"/>
</summary>
</jasperReport>
<?xml version="1.0" encoding="UTF-8"?>
<!-- Created with Jaspersoft Studio version 6.20.5.final using JasperReports Library version 6.20.5-3efcf2e67f959db3888d79f73dde2dbd7acb4f8e -->
<jasperReport xmlns="http://jasperreports.sourceforge.net/jasperreports" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://jasperreports.sourceforge.net/jasperreports http://jasperreports.sourceforge.net/xsd/jasperreport.xsd" name="users" language="groovy" pageWidth="595" pageHeight="842" columnWidth="555" leftMargin="20" rightMargin="20" topMargin="20" bottomMargin="20" uuid="cc1a9dab-bb8a-4181-94ac-73c3dc91137c">
<property name="ireport.zoom" value="1.3310000000000004"/>
<property name="ireport.x" value="0"/>
<property name="ireport.y" value="0"/>
<property name="com.jaspersoft.studio.data.defaultdataadapter" value="DatabaseAdapter.jrdax"/>
<property name="com.jaspersoft.studio.data.sql.tables" value=""/>
<parameter name="judul" class="java.lang.String"/>
<parameter name="logo" class="java.lang.String"/>
<queryString>
<![CDATA[SELECT *
FROM res_provinsi]]>
</queryString>
<field name="kategori" class="java.lang.String">
<property name="com.jaspersoft.studio.field.name" value="kategori"/>
<property name="com.jaspersoft.studio.field.label" value="kategori"/>
<property name="com.jaspersoft.studio.field.tree.path" value="res_provinsi"/>
</field>
<field name="ibu_kota" class="java.lang.String">
<property name="com.jaspersoft.studio.field.name" value="ibu_kota"/>
<property name="com.jaspersoft.studio.field.label" value="ibu_kota"/>
<property name="com.jaspersoft.studio.field.tree.path" value="res_provinsi"/>
</field>
<field name="nama" class="java.lang.String">
<property name="com.jaspersoft.studio.field.name" value="nama"/>
<property name="com.jaspersoft.studio.field.label" value="nama"/>
<property name="com.jaspersoft.studio.field.tree.path" value="res_provinsi"/>
</field>
<field name="kode" class="java.lang.String">
<property name="com.jaspersoft.studio.field.name" value="kode"/>
<property name="com.jaspersoft.studio.field.label" value="kode"/>
<property name="com.jaspersoft.studio.field.tree.path" value="res_provinsi"/>
</field>
<field name="status" class="java.lang.Integer">
<property name="com.jaspersoft.studio.field.name" value="status"/>
<property name="com.jaspersoft.studio.field.label" value="status"/>
<property name="com.jaspersoft.studio.field.tree.path" value="res_provinsi"/>
</field>
<field name="created" class="java.sql.Timestamp">
<property name="com.jaspersoft.studio.field.name" value="created"/>
<property name="com.jaspersoft.studio.field.label" value="created"/>
<property name="com.jaspersoft.studio.field.tree.path" value="res_provinsi"/>
</field>
<field name="updated" class="java.sql.Timestamp">
<property name="com.jaspersoft.studio.field.name" value="updated"/>
<property name="com.jaspersoft.studio.field.label" value="updated"/>
<property name="com.jaspersoft.studio.field.tree.path" value="res_provinsi"/>
</field>
<field name="create_uid" class="java.lang.Integer">
<property name="com.jaspersoft.studio.field.name" value="create_uid"/>
<property name="com.jaspersoft.studio.field.label" value="create_uid"/>
<property name="com.jaspersoft.studio.field.tree.path" value="res_provinsi"/>
</field>
<field name="update_uid" class="java.lang.Integer">
<property name="com.jaspersoft.studio.field.name" value="update_uid"/>
<property name="com.jaspersoft.studio.field.label" value="update_uid"/>
<property name="com.jaspersoft.studio.field.tree.path" value="res_provinsi"/>
</field>
<field name="id" class="java.lang.Integer">
<property name="com.jaspersoft.studio.field.name" value="id"/>
<property name="com.jaspersoft.studio.field.label" value="id"/>
<property name="com.jaspersoft.studio.field.tree.path" value="res_provinsi"/>
</field>
<background>
<band splitType="Stretch"/>
</background>
<title>
<band height="73" splitType="Stretch">
<staticText>
<reportElement x="63" y="40" width="492" height="20" uuid="abe9cbb1-2e91-4eb0-b3ee-05e9a967c5f6"/>
<textElement textAlignment="Center">
<font size="14" isBold="true"/>
</textElement>
<text><![CDATA[DAFTAR PROVINSI]]></text>
</staticText>
<image>
<reportElement x="10" y="10" width="53" height="58" uuid="3fe2de31-ff3e-4451-8d0d-6b2753184c09"/>
<imageExpression><![CDATA[$P{logo}]]></imageExpression>
</image>
<textField>
<reportElement x="63" y="10" width="492" height="30" uuid="00412b89-3587-423f-8aaf-1526e5f32540"/>
<textElement textAlignment="Center">
<font size="20" isBold="true"/>
</textElement>
<textFieldExpression><![CDATA[$P{judul}]]></textFieldExpression>
</textField>
</band>
</title>
<pageHeader>
<band height="7" splitType="Stretch">
<line>
<reportElement x="0" y="-5" width="555" height="1" uuid="10e401ac-e33c-4e46-b2e1-62703f3cea4e"/>
<graphicElement>
<pen lineWidth="4.0"/>
</graphicElement>
</line>
</band>
</pageHeader>
<columnHeader>
<band height="20" splitType="Stretch">
<staticText>
<reportElement x="0" y="0" width="100" height="20" uuid="45c2cace-4a3f-495c-9002-be2f2ac8eca4"/>
<box topPadding="0" leftPadding="0" bottomPadding="0" rightPadding="0">
<topPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<leftPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<bottomPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<rightPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
</box>
<textElement textAlignment="Center">
<font isBold="true" isUnderline="true"/>
</textElement>
<text><![CDATA[Kode]]></text>
</staticText>
<staticText>
<reportElement x="100" y="0" width="255" height="20" uuid="3a03e8b0-96f7-4754-b00e-ceae1a0e5aa9"/>
<box>
<topPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<leftPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<bottomPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<rightPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
</box>
<textElement textAlignment="Center">
<font isBold="true" isUnderline="true"/>
</textElement>
<text><![CDATA[Nama]]></text>
</staticText>
<staticText>
<reportElement x="355" y="0" width="200" height="20" uuid="f19e05c8-f1bf-4d94-927d-07111ed068df"/>
<box topPadding="0" leftPadding="0" bottomPadding="0" rightPadding="0">
<topPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<leftPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<bottomPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<rightPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
</box>
<textElement textAlignment="Center">
<font isBold="true" isUnderline="true"/>
</textElement>
<text><![CDATA[Ibu Kota]]></text>
</staticText>
</band>
</columnHeader>
<detail>
<band height="20" splitType="Stretch">
<textField>
<reportElement x="0" y="0" width="100" height="20" uuid="aec5f07a-b9fb-4ce1-9e7e-957f6315acb0"/>
<box topPadding="0" leftPadding="0" bottomPadding="0" rightPadding="0">
<topPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<leftPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<bottomPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<rightPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
</box>
<textElement textAlignment="Center"/>
<textFieldExpression><![CDATA[$F{kode}]]></textFieldExpression>
</textField>
<textField>
<reportElement x="100" y="0" width="255" height="20" uuid="04eef3a7-87ca-4a27-9392-1368a6ba2fd1"/>
<box topPadding="0" leftPadding="0" bottomPadding="0" rightPadding="0">
<topPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<leftPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<bottomPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<rightPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
</box>
<textElement textAlignment="Center"/>
<textFieldExpression><![CDATA[$F{nama}]]></textFieldExpression>
</textField>
<textField>
<reportElement x="355" y="0" width="200" height="20" uuid="47051f05-f634-4c32-97cc-ce9af7b8f382"/>
<box topPadding="0" leftPadding="0" bottomPadding="0" rightPadding="0">
<topPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<leftPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<bottomPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<rightPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
</box>
<textElement textAlignment="Center"/>
<textFieldExpression><![CDATA[$F{ibu_kota}]]></textFieldExpression>
</textField>
</band>
</detail>
<columnFooter>
<band height="45" splitType="Stretch"/>
</columnFooter>
<pageFooter>
<band height="54" splitType="Stretch"/>
</pageFooter>
<summary>
<band height="42" splitType="Stretch"/>
</summary>
</jasperReport>
<?xml version="1.0" encoding="UTF-8"?>
<!-- Created with Jaspersoft Studio version 6.20.5.final using JasperReports Library version 6.20.5-3efcf2e67f959db3888d79f73dde2dbd7acb4f8e -->
<jasperReport xmlns="http://jasperreports.sourceforge.net/jasperreports" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://jasperreports.sourceforge.net/jasperreports http://jasperreports.sourceforge.net/xsd/jasperreport.xsd" name="users" language="groovy" pageWidth="595" pageHeight="842" columnWidth="555" leftMargin="20" rightMargin="20" topMargin="20" bottomMargin="20" uuid="cc1a9dab-bb8a-4181-94ac-73c3dc91137c">
<property name="ireport.zoom" value="1.3310000000000004"/>
<property name="ireport.x" value="0"/>
<property name="ireport.y" value="0"/>
<property name="com.jaspersoft.studio.data.sql.tables" value=""/>
<property name="com.jaspersoft.studio.data.defaultdataadapter" value="DatabaseAdapter.jrdax"/>
<parameter name="judul" class="java.lang.String"/>
<parameter name="logo" class="java.lang.String"/>
<queryString>
<![CDATA[SELECT *
FROM external_identities]]>
</queryString>
<field name="external_id" class="java.lang.String">
<property name="com.jaspersoft.studio.field.name" value="external_id"/>
<property name="com.jaspersoft.studio.field.label" value="external_id"/>
<property name="com.jaspersoft.studio.field.tree.path" value="external_identities"/>
</field>
<field name="external_user_name" class="java.lang.String">
<property name="com.jaspersoft.studio.field.name" value="external_user_name"/>
<property name="com.jaspersoft.studio.field.label" value="external_user_name"/>
<property name="com.jaspersoft.studio.field.tree.path" value="external_identities"/>
</field>
<field name="local_user_id" class="java.lang.Integer">
<property name="com.jaspersoft.studio.field.name" value="local_user_id"/>
<property name="com.jaspersoft.studio.field.label" value="local_user_id"/>
<property name="com.jaspersoft.studio.field.tree.path" value="external_identities"/>
</field>
<field name="provider_name" class="java.lang.String">
<property name="com.jaspersoft.studio.field.name" value="provider_name"/>
<property name="com.jaspersoft.studio.field.label" value="provider_name"/>
<property name="com.jaspersoft.studio.field.tree.path" value="external_identities"/>
</field>
<field name="access_token" class="java.lang.String">
<property name="com.jaspersoft.studio.field.name" value="access_token"/>
<property name="com.jaspersoft.studio.field.label" value="access_token"/>
<property name="com.jaspersoft.studio.field.tree.path" value="external_identities"/>
</field>
<field name="alt_token" class="java.lang.String">
<property name="com.jaspersoft.studio.field.name" value="alt_token"/>
<property name="com.jaspersoft.studio.field.label" value="alt_token"/>
<property name="com.jaspersoft.studio.field.tree.path" value="external_identities"/>
</field>
<field name="token_secret" class="java.lang.String">
<property name="com.jaspersoft.studio.field.name" value="token_secret"/>
<property name="com.jaspersoft.studio.field.label" value="token_secret"/>
<property name="com.jaspersoft.studio.field.tree.path" value="external_identities"/>
</field>
<background>
<band splitType="Stretch"/>
</background>
<title>
<band height="73" splitType="Stretch">
<staticText>
<reportElement x="63" y="40" width="492" height="20" uuid="abe9cbb1-2e91-4eb0-b3ee-05e9a967c5f6"/>
<textElement textAlignment="Center">
<font size="14" isBold="true"/>
</textElement>
<text><![CDATA[DAFTAR EXTERNAL USER]]></text>
</staticText>
<image>
<reportElement x="10" y="10" width="53" height="58" uuid="3fe2de31-ff3e-4451-8d0d-6b2753184c09"/>
<imageExpression><![CDATA[$P{logo}]]></imageExpression>
</image>
<textField>
<reportElement x="63" y="10" width="492" height="30" uuid="00412b89-3587-423f-8aaf-1526e5f32540"/>
<textElement textAlignment="Center">
<font size="20" isBold="true"/>
</textElement>
<textFieldExpression><![CDATA[$P{judul}]]></textFieldExpression>
</textField>
</band>
</title>
<pageHeader>
<band height="10" splitType="Stretch">
<line>
<reportElement x="0" y="-5" width="555" height="1" uuid="7b197a7c-c9f8-4564-8934-0c288f892b7d"/>
<graphicElement>
<pen lineWidth="4.0"/>
</graphicElement>
</line>
</band>
</pageHeader>
<columnHeader>
<band height="20" splitType="Stretch">
<staticText>
<reportElement x="0" y="0" width="100" height="20" uuid="45c2cace-4a3f-495c-9002-be2f2ac8eca4"/>
<box topPadding="0" leftPadding="0" bottomPadding="0" rightPadding="0">
<topPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<leftPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<bottomPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<rightPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
</box>
<textElement textAlignment="Center">
<font isBold="true" isUnderline="true"/>
</textElement>
<text><![CDATA[User Name]]></text>
</staticText>
<staticText>
<reportElement x="100" y="0" width="255" height="20" uuid="3a03e8b0-96f7-4754-b00e-ceae1a0e5aa9"/>
<box>
<topPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<leftPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<bottomPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<rightPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
</box>
<textElement textAlignment="Center">
<font isBold="true" isUnderline="true"/>
</textElement>
<text><![CDATA[Provider]]></text>
</staticText>
<staticText>
<reportElement x="355" y="0" width="200" height="20" uuid="f19e05c8-f1bf-4d94-927d-07111ed068df"/>
<box topPadding="0" leftPadding="0" bottomPadding="0" rightPadding="0">
<topPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<leftPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<bottomPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<rightPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
</box>
<textElement textAlignment="Center">
<font isBold="true" isUnderline="true"/>
</textElement>
<text><![CDATA[User ID]]></text>
</staticText>
</band>
</columnHeader>
<detail>
<band height="20" splitType="Stretch">
<textField>
<reportElement x="0" y="0" width="100" height="20" uuid="aec5f07a-b9fb-4ce1-9e7e-957f6315acb0"/>
<box topPadding="0" leftPadding="0" bottomPadding="0" rightPadding="0">
<topPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<leftPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<bottomPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<rightPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
</box>
<textElement textAlignment="Center"/>
<textFieldExpression><![CDATA[$F{external_user_name}]]></textFieldExpression>
</textField>
<textField>
<reportElement x="100" y="0" width="255" height="20" uuid="04eef3a7-87ca-4a27-9392-1368a6ba2fd1"/>
<box topPadding="0" leftPadding="0" bottomPadding="0" rightPadding="0">
<topPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<leftPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<bottomPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<rightPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
</box>
<textElement textAlignment="Center"/>
<textFieldExpression><![CDATA[$F{provider_name}]]></textFieldExpression>
</textField>
<textField>
<reportElement x="355" y="0" width="200" height="20" uuid="47051f05-f634-4c32-97cc-ce9af7b8f382"/>
<box topPadding="0" leftPadding="0" bottomPadding="0" rightPadding="0">
<topPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<leftPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<bottomPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<rightPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
</box>
<textElement textAlignment="Center"/>
<textFieldExpression><![CDATA[$F{local_user_id}]]></textFieldExpression>
</textField>
</band>
</detail>
<columnFooter>
<band height="45" splitType="Stretch"/>
</columnFooter>
<pageFooter>
<band height="54" splitType="Stretch"/>
</pageFooter>
<summary>
<band height="42" splitType="Stretch"/>
</summary>
</jasperReport>
......@@ -6,12 +6,8 @@
<property name="ireport.y" value="0"/>
<property name="com.jaspersoft.studio.data.defaultdataadapter" value="DemoAdapter.jrdax"/>
<property name="com.jaspersoft.studio.data.sql.tables" value=""/>
<parameter name="Judul" class="java.lang.String">
<defaultValueExpression><![CDATA[PEMERINTAH TANGERANG]]></defaultValueExpression>
</parameter>
<parameter name="Logo" class="java.lang.String">
<defaultValueExpression><![CDATA["C:\\Users\\ASUS\\Downloads\\bangkit.png"]]></defaultValueExpression>
</parameter>
<parameter name="judul" class="java.lang.String"/>
<parameter name="logo" class="java.lang.String"/>
<queryString>
<![CDATA[SELECT *
FROM users]]>
......@@ -34,22 +30,22 @@ FROM users]]>
<title>
<band height="73" splitType="Stretch">
<staticText>
<reportElement x="230" y="40" width="130" height="20" uuid="abe9cbb1-2e91-4eb0-b3ee-05e9a967c5f6"/>
<textElement>
<reportElement x="63" y="40" width="492" height="20" uuid="abe9cbb1-2e91-4eb0-b3ee-05e9a967c5f6"/>
<textElement textAlignment="Center">
<font size="14" isBold="true"/>
</textElement>
<text><![CDATA[DAFTAR PARTNER]]></text>
<text><![CDATA[DAFTAR USER]]></text>
</staticText>
<image>
<reportElement x="10" y="10" width="53" height="58" uuid="3fe2de31-ff3e-4451-8d0d-6b2753184c09"/>
<imageExpression><![CDATA[$P{Logo}]]></imageExpression>
<imageExpression><![CDATA[$P{logo}]]></imageExpression>
</image>
<textField>
<reportElement x="-20" y="10" width="595" height="30" uuid="00412b89-3587-423f-8aaf-1526e5f32540"/>
<reportElement x="63" y="10" width="492" height="30" uuid="00412b89-3587-423f-8aaf-1526e5f32540"/>
<textElement textAlignment="Center">
<font size="20" isBold="true"/>
</textElement>
<textFieldExpression><![CDATA[$P{Judul}]]></textFieldExpression>
<textFieldExpression><![CDATA[$P{judul}]]></textFieldExpression>
</textField>
</band>
</title>
......@@ -60,6 +56,12 @@ FROM users]]>
<band height="20" splitType="Stretch">
<staticText>
<reportElement x="0" y="0" width="100" height="20" uuid="45c2cace-4a3f-495c-9002-be2f2ac8eca4"/>
<box topPadding="0" leftPadding="0" bottomPadding="0" rightPadding="0">
<topPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<leftPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<bottomPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<rightPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
</box>
<textElement textAlignment="Center">
<font isBold="true" isUnderline="true"/>
</textElement>
......@@ -67,6 +69,12 @@ FROM users]]>
</staticText>
<staticText>
<reportElement x="100" y="0" width="255" height="20" uuid="3a03e8b0-96f7-4754-b00e-ceae1a0e5aa9"/>
<box>
<topPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<leftPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<bottomPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<rightPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
</box>
<textElement textAlignment="Center">
<font isBold="true" isUnderline="true"/>
</textElement>
......@@ -74,6 +82,12 @@ FROM users]]>
</staticText>
<staticText>
<reportElement x="355" y="0" width="100" height="20" uuid="f19e05c8-f1bf-4d94-927d-07111ed068df"/>
<box topPadding="0" leftPadding="0" bottomPadding="0" rightPadding="0">
<topPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<leftPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<bottomPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<rightPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
</box>
<textElement textAlignment="Center">
<font isBold="true" isUnderline="true"/>
</textElement>
......@@ -81,6 +95,12 @@ FROM users]]>
</staticText>
<staticText>
<reportElement x="455" y="0" width="100" height="20" uuid="8a8040c2-e6ba-4473-835f-c9cfe3568fb9"/>
<box topPadding="0" leftPadding="0" bottomPadding="0" rightPadding="0">
<topPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<leftPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<bottomPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<rightPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
</box>
<textElement textAlignment="Center">
<font isBold="true" isUnderline="true"/>
</textElement>
......@@ -89,24 +109,48 @@ FROM users]]>
</band>
</columnHeader>
<detail>
<band height="22" splitType="Stretch">
<band height="20" splitType="Stretch">
<textField>
<reportElement x="0" y="0" width="100" height="20" uuid="aec5f07a-b9fb-4ce1-9e7e-957f6315acb0"/>
<box topPadding="0" leftPadding="0" bottomPadding="0" rightPadding="0">
<topPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<leftPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<bottomPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<rightPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
</box>
<textElement textAlignment="Center"/>
<textFieldExpression><![CDATA[$F{user_name}]]></textFieldExpression>
</textField>
<textField>
<reportElement x="100" y="0" width="255" height="20" uuid="04eef3a7-87ca-4a27-9392-1368a6ba2fd1"/>
<box topPadding="0" leftPadding="0" bottomPadding="0" rightPadding="0">
<topPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<leftPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<bottomPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<rightPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
</box>
<textElement textAlignment="Center"/>
<textFieldExpression><![CDATA[$F{email}]]></textFieldExpression>
</textField>
<textField>
<reportElement x="455" y="0" width="100" height="20" uuid="24a12a8f-a1e1-4ae3-adb7-bbcf450560ee"/>
<box topPadding="0" leftPadding="0" bottomPadding="0" rightPadding="0">
<topPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<leftPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<bottomPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<rightPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
</box>
<textElement textAlignment="Center"/>
<textFieldExpression><![CDATA[$F{registered_date}]]></textFieldExpression>
</textField>
<textField>
<reportElement x="355" y="0" width="100" height="20" uuid="47051f05-f634-4c32-97cc-ce9af7b8f382"/>
<box topPadding="0" leftPadding="0" bottomPadding="0" rightPadding="0">
<topPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<leftPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<bottomPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
<rightPen lineWidth="1.0" lineStyle="Solid" lineColor="#000000"/>
</box>
<textElement textAlignment="Center"/>
<textFieldExpression><![CDATA[$F{status}]]></textFieldExpression>
</textField>
......
......@@ -89,10 +89,10 @@ def jasper_export(input_file, output_file=None, schema=None,
module_file = input_file[0]
input_file = input_file[1]
if module_file:
path = __import__(module_file)
path = os.path.dirname(path.__file__)
input_file = os.path.join(path, input_file)
if module_file:
path = __import__(module_file)
path = os.path.dirname(path.__file__)
input_file = os.path.join(path, input_file)
else:
input_file = input_file[0]
......
from . import DataTables, button_import
import os
from . import DataTables, button_import, get_params
from .partner_base import PartnerSchema
from .. import get_urls
from ..views import BaseView
......@@ -13,7 +14,10 @@ from sqlalchemy.orm import aliased
from opensipkd.models import DBSession, ResCompany, ResKecamatan, Partner
from opensipkd.models import ResProvinsi, ResDati2, ResDesa, User
from opensipkd.tools.buttons import btn_upload
from opensipkd.tools.report import file_response
# lib buat mendapatkan full path asset
from pyramid.path import AssetResolver
log = logging.getLogger(__name__)
SESS_ADD_FAILED = 'Tambah pemda gagal'
......@@ -100,6 +104,10 @@ class ViewCompany(BaseView):
self.table = ResCompany
self.list_buttons = self.list_buttons + self.list_report + (button_import,)
path = os.path.dirname(__file__)
path = os.path.dirname(path)
self.report_file = os.path.join(path, 'reports', 'pemerintah.jrxml')
def form_validator(self, form, value):
err = colander.Invalid(form, "")
......@@ -194,42 +202,61 @@ class ViewCompany(BaseView):
self.table.id == self.req.user.company_id)
return query
# Mendapatkan path gambar
def get_module_path(self, module_name):
a = AssetResolver(module_name)
resolver = a.resolve('')
return resolver.abspath()
def pdf_response(self, **kwargs):
from opensipkd.base.tools.report import jasper_export
logo = self.get_module_path('opensipkd.base')
logo = os.path.join(logo, 'static', 'img', 'logo.png')
parameters = {
"judul": get_params('company', "openSIPKD"),
"logo": logo
}
print(parameters)
filename = jasper_export(self.report_file, parameters=parameters)
return file_response(self.req, filename=filename[0])
@view_config(
route_name='company-act',
renderer='json',
permission='view')
def view_act(self):
request = self.req
ses = request.session
params = request.params
url_dict = request.matchdict
alias = aliased(ResCompany)
if url_dict['act'] == 'grid':
columns = [ColumnDT(self.table.id, mData='id'),
ColumnDT(self.table.kode, mData='kode'),
ColumnDT(self.table.nama, mData='nama'),
ColumnDT(alias.nama, mData='parent_nm'),
ColumnDT(self.table.status, mData='status'),
# ColumnDT(Departemen.level_id, mData='level_id'),
]
query = DBSession.query().select_from(ResCompany).outerjoin(
alias, ResCompany.parent_id == alias.id)
query = self.filter_company(query)
row_table = DataTables(request.GET, query, columns)
return row_table.output_result()
elif url_dict['act'] == 'hon':
term = 'term' in params and params['term'] or ''
q = DBSession.query(self.table) \
.filter(self.table.status == 1,
self.table.nama.ilike('%%%s%%' % term)) \
.order_by(self.table.nama)
rows = q.all()
r = []
for k in rows:
d = dict(id=k.id, value=k.nama, kode=k.kode, nama=k.nama)
r.append(d)
log.error(r)
return r
# request = self.req
# ses = request.session
# params = request.params
# url_dict = request.matchdict
# alias = aliased(ResCompany)
# if url_dict['act'] == 'grid':
# columns = [ColumnDT(self.table.id, mData='id'),
# ColumnDT(self.table.kode, mData='kode'),
# ColumnDT(self.table.nama, mData='nama'),
# ColumnDT(alias.nama, mData='parent_nm'),
# ColumnDT(self.table.status, mData='status'),
# # ColumnDT(Departemen.level_id, mData='level_id'),
# ]
# query = DBSession.query().select_from(ResCompany).outerjoin(
# alias, ResCompany.parent_id == alias.id)
# query = self.filter_company(query)
# row_table = DataTables(request.GET, query, columns)
# return row_table.output_result()
# elif url_dict['act'] == 'hon':
# term = 'term' in params and params['term'] or ''
# q = DBSession.query(self.table) \
# .filter(self.table.status == 1,
# self.table.nama.ilike('%%%s%%' % term)) \
# .order_by(self.table.nama)
# rows = q.all()
# r = []
# for k in rows:
# d = dict(id=k.id, value=k.nama, kode=k.kode, nama=k.nama)
# r.append(d)
# log.error(r)
# return r
return super(ViewCompany, self).view_act()
@view_config(
route_name='company-add',
......@@ -261,7 +288,7 @@ class ViewCompany(BaseView):
@view_config(
route_name='company-delete',
renderer='templates/form_input.pt',
renderer='templates/form.pt',
permission='company')
def view_delete(self):
return super(ViewCompany, self).view_delete()
......
import os
import colander
from . import button_import
from .company import company_widget
from .. import get_params
from ..views import ColumnDT, DataTables, BaseView, get_urls
from datetime import datetime
from deform import (widget, )
from opensipkd.models import DBSession, Departemen, Partner, PartnerDepartemen, ResCompany
from opensipkd.tools import (get_settings)
from opensipkd.tools.report import file_response
#from opensipkd.tools.report import pdf_response
from pyramid.view import (view_config, )
from sqlalchemy import func
from sqlalchemy.orm import aliased
# lib buat mendapatkan full path asset
from pyramid.path import AssetResolver
SESS_ADD_FAILED = 'Tambah departemen gagal'
SESS_EDIT_FAILED = 'Edit departemen gagal'
......@@ -152,7 +158,12 @@ class ViewDepartemen(BaseView):
# self.list_url = 'departemen'
self.list_route = 'departemen'
self.form_scripts = ""
self.list_buttons = self.list_buttons + (button_import,)
self.list_buttons = self.list_buttons + self.list_report + (button_import,)
path = os.path.dirname(__file__)
path = os.path.dirname(path)
self.report_file = os.path.join(path, 'reports', 'departemen.jrxml')
def form_validator(self, form, value):
def err_kode():
......@@ -228,123 +239,143 @@ class ViewDepartemen(BaseView):
def view_list(self):
return super().view_list()
# Mendapatkan path gambar
def get_module_path(self, module_name):
a = AssetResolver(module_name)
resolver = a.resolve('')
return resolver.abspath()
# Mencetak PDF
def pdf_response(self, **kwargs):
from opensipkd.base.tools.report import jasper_export
logo = self.get_module_path('opensipkd.base')
logo = os.path.join(logo, 'static', 'img', 'logo.png')
parameters = {
"judul": get_params('company', "openSIPKD"),
"logo": logo
}
print(parameters)
filename = jasper_export(self.report_file, parameters=parameters)
return file_response(self.req, filename=filename[0])
@view_config(route_name='departemen-act', renderer='json',
permission='view')
def view_act(self):
request = self.req
ses = request.session
params = request.params
url_dict = request.matchdict
dep_alias = aliased(Departemen)
if url_dict['act'] == 'grid':
columns = [ColumnDT(Departemen.id, mData='id'),
ColumnDT(Departemen.kode, mData='kode'),
ColumnDT(Departemen.nama, mData='nama'),
ColumnDT(dep_alias.nama, mData='parent'),
ColumnDT(Departemen.status, mData='status'),
ColumnDT(Departemen.level_id, mData='level_id'),
ColumnDT(ResCompany.nama, mData='company_nm'), ]
query = DBSession.query().select_from(Departemen).outerjoin(
dep_alias, Departemen.parent_id == dep_alias.id).outerjoin(
ResCompany, self.table.company_id == ResCompany.id
)
query = self.filter_company(query)
row_table = DataTables(request.GET, query, columns)
return row_table.output_result()
elif url_dict['act'] == 'hon':
term = 'term' in params and params['term'] or ''
q = DBSession.query(Departemen). \
filter(Departemen.status == 1,
Departemen.nama.ilike('%%%s%%' % term)) \
.order_by(
Departemen.nama)
if self.req.user.company_id:
q = q.filter(Departemen.company_id == self.req.user.company_id)
rows = q.all()
r = []
for k in rows:
d = dict(id=k.id, value=k.nama, kode=k.kode, nama=k.nama,
level_id=k.level_id)
r.append(d)
return r
elif url_dict['act'] == 'honk':
term = 'term' in params and params['term'] or ''
q = DBSession.query(Departemen) \
.filter(Departemen.status == 1,
func.concat(Departemen.nama, ';',
Departemen.kode) \
.ilike('%%%s%%' % term)) \
.order_by(Departemen.nama)
q = self.filter_company(q)
rows = q.all()
r = []
for k in rows:
d = dict(id=k.id, value=k.nama + ';' + k.kode, kode=k.kode,
nama=k.nama, level_id=k.level_id)
r.append(d)
return r
elif url_dict['act'] == 'hon_level':
# todo Check ulang untuk hon
term = 'term' in params and params['term'] or ''
settings = get_settings()
level_id = get_params('departemen_chg_id', 0)
q = DBSession.query(Departemen).filter(Departemen.status == 1,
Departemen.nama.ilike(
'%%%s%%' %
term)).order_by(
Departemen.nama)
if self.req.user.company_id:
q = q.filter(Departemen.company_id == self.req.user.company_id)
if int(level_id) > 0:
q = q.filter(Departemen.level_id == int(level_id))
if request.user.id > 1 and not request.has_permission(
"departemen-all"):
partner = Partner.query_id(request.user.id).first()
if partner:
PartnerDepartemen.query_jabatan(partner.id, datetime.now())
user_dep = PartnerDepartemen.query_user_id().first()
if not user_dep:
return []
kode = user_dep.departemen.kode
if user_dep.sub_departemen:
q = q.filter(Departemen.kode.ilike('{}%'.format(kode)))
else:
q = q.filter(Departemen.kode == kode)
rows = q.all()
r = []
for k in rows:
d = dict(id=k.id, value=k.nama, kode=k.kode, nama=k.nama,
level_id=k.level_id)
r.append(d)
return r
elif url_dict['act'] == 'hon_all':
term = 'term' in params and params['term'] or ''
settings = get_settings()
level_id = 'departemen_chg_id' in settings and settings[
'departemen_chg_id'] or 0
q = DBSession.query(Departemen).filter(Departemen.status == 1,
Departemen.nama.ilike(
'%%%s%%' %
term)).order_by(
Departemen.nama)
if self.req.user.company_id:
q = q.filter(Departemen.company_id == self.req.user.company_id)
if int(level_id) > 0:
q = q.filter(Departemen.level_id == int(level_id))
rows = q.all()
r = []
for k in rows:
d = dict(id=k.id, value=k.nama, kode=k.kode, nama=k.nama,
level_id=k.level_id)
r.append(d)
return r
# request = self.req
# ses = request.session
# params = request.params
# url_dict = request.matchdict
# dep_alias = aliased(Departemen)
# if url_dict['act'] == 'grid':
# columns = [ColumnDT(Departemen.id, mData='id'),
# ColumnDT(Departemen.kode, mData='kode'),
# ColumnDT(Departemen.nama, mData='nama'),
# ColumnDT(dep_alias.nama, mData='parent'),
# ColumnDT(Departemen.status, mData='status'),
# ColumnDT(Departemen.level_id, mData='level_id'),
# ColumnDT(ResCompany.nama, mData='company_nm'), ]
# query = DBSession.query().select_from(Departemen).outerjoin(
# dep_alias, Departemen.parent_id == dep_alias.id).outerjoin(
# ResCompany, self.table.company_id == ResCompany.id
# )
# query = self.filter_company(query)
# row_table = DataTables(request.GET, query, columns)
# return row_table.output_result()
# elif url_dict['act'] == 'hon':
# term = 'term' in params and params['term'] or ''
# q = DBSession.query(Departemen). \
# filter(Departemen.status == 1,
# Departemen.nama.ilike('%%%s%%' % term)) \
# .order_by(
# Departemen.nama)
# if self.req.user.company_id:
# q = q.filter(Departemen.company_id == self.req.user.company_id)
# rows = q.all()
# r = []
# for k in rows:
# d = dict(id=k.id, value=k.nama, kode=k.kode, nama=k.nama,
# level_id=k.level_id)
# r.append(d)
# return r
# elif url_dict['act'] == 'honk':
# term = 'term' in params and params['term'] or ''
# q = DBSession.query(Departemen) \
# .filter(Departemen.status == 1,
# func.concat(Departemen.nama, ';',
# Departemen.kode) \
# .ilike('%%%s%%' % term)) \
# .order_by(Departemen.nama)
# q = self.filter_company(q)
# rows = q.all()
# r = []
# for k in rows:
# d = dict(id=k.id, value=k.nama + ';' + k.kode, kode=k.kode,
# nama=k.nama, level_id=k.level_id)
# r.append(d)
# return r
# elif url_dict['act'] == 'hon_level':
# # todo Check ulang untuk hon
# term = 'term' in params and params['term'] or ''
# settings = get_settings()
# level_id = get_params('departemen_chg_id', 0)
# q = DBSession.query(Departemen).filter(Departemen.status == 1,
# Departemen.nama.ilike(
# '%%%s%%' %
# term)).order_by(
# Departemen.nama)
# if self.req.user.company_id:
# q = q.filter(Departemen.company_id == self.req.user.company_id)
# if int(level_id) > 0:
# q = q.filter(Departemen.level_id == int(level_id))
# if request.user.id > 1 and not request.has_permission(
# "departemen-all"):
# partner = Partner.query_id(request.user.id).first()
# if partner:
# PartnerDepartemen.query_jabatan(partner.id, datetime.now())
# user_dep = PartnerDepartemen.query_user_id().first()
# if not user_dep:
# return []
# kode = user_dep.departemen.kode
# if user_dep.sub_departemen:
# q = q.filter(Departemen.kode.ilike('{}%'.format(kode)))
# else:
# q = q.filter(Departemen.kode == kode)
# rows = q.all()
# r = []
# for k in rows:
# d = dict(id=k.id, value=k.nama, kode=k.kode, nama=k.nama,
# level_id=k.level_id)
# r.append(d)
# return r
# elif url_dict['act'] == 'hon_all':
# term = 'term' in params and params['term'] or ''
# settings = get_settings()
# level_id = 'departemen_chg_id' in settings and settings[
# 'departemen_chg_id'] or 0
# q = DBSession.query(Departemen).filter(Departemen.status == 1,
# Departemen.nama.ilike(
# '%%%s%%' %
# term)).order_by(
# Departemen.nama)
# if self.req.user.company_id:
# q = q.filter(Departemen.company_id == self.req.user.company_id)
# if int(level_id) > 0:
# q = q.filter(Departemen.level_id == int(level_id))
# rows = q.all()
# r = []
# for k in rows:
# d = dict(id=k.id, value=k.nama, kode=k.kode, nama=k.nama,
# level_id=k.level_id)
# r.append(d)
# return r
return super(ViewDepartemen, self).view_act()
def get_bindings(self, row=None):
return {"company_list": ResCompany.get_list(),
......
from . import widget_os, button_import
import os
from . import widget_os, button_import, get_params
from ..views import BaseView
import colander
......@@ -7,7 +8,10 @@ from pyramid.i18n import TranslationStringFactory
from pyramid.view import (view_config, )
from opensipkd.models import DBSession, ResProvinsi, kategori_provinsi
from opensipkd.tools.buttons import btn_upload
from opensipkd.tools.report import file_response
# lib buat mendapatkan full path asset
from pyramid.path import AssetResolver
_ = TranslationStringFactory("opensipkd")
......@@ -83,6 +87,10 @@ class ViewProvinsi(BaseView):
self.table = ResProvinsi
self.list_buttons = self.list_buttons + self.list_report + (button_import,)
path = os.path.dirname(__file__)
path = os.path.dirname(path)
self.report_file = os.path.join(path, 'reports', 'provinsi.jrxml')
########
# List #
########
......@@ -134,6 +142,24 @@ class ViewProvinsi(BaseView):
def view_list(self):
return super(ViewProvinsi, self).view_list()
# Mendapatkan path gambar
def get_module_path(self, module_name):
a = AssetResolver(module_name)
resolver = a.resolve('')
return resolver.abspath()
def pdf_response(self, **kwargs):
from opensipkd.base.tools.report import jasper_export
logo = self.get_module_path('opensipkd.base')
logo = os.path.join(logo, 'static', 'img', 'logo.png')
parameters = {
"judul": get_params('company', "openSIPKD"),
"logo": logo
}
print(parameters)
filename = jasper_export(self.report_file, parameters=parameters)
return file_response(self.req, filename=filename[0])
@view_config(
route_name='provinsi-act',
renderer='json',
......
from . import BaseView, button_import
from . import BaseView, button_import, get_params
from .company import company_widget
from .user_login import (regenerate_security_code, send_email_security_code, generate_api_key,)
import os
......@@ -14,6 +14,9 @@ from pyramid.view import view_config
from sqlalchemy import (func,)
from ziggurat_foundations.models.services.user import UserService
# lib buat mendapatkan full path asset
from pyramid.path import AssetResolver
_ = TranslationStringFactory('user')
......@@ -85,6 +88,24 @@ class Views(BaseView):
def view_list(self):
return super(Views, self).view_list()
# Mendapatkan path gambar
def get_module_path(self, module_name):
a = AssetResolver(module_name)
resolver = a.resolve('')
return resolver.abspath()
def pdf_response(self, **kwargs):
from opensipkd.base.tools.report import jasper_export
logo = self.get_module_path('opensipkd.base')
logo = os.path.join(logo, 'static', 'img', 'logo.png')
parameters = {
"judul": get_params('company', "openSIPKD"),
"logo": logo
}
print(parameters)
filename = jasper_export(self.report_file, parameters=parameters)
return file_response(self.req, filename=filename[0])
@view_config(
route_name='user-act',
renderer='json',
......@@ -102,7 +123,7 @@ class Views(BaseView):
# 'rows': rows,
# }
# return csv_response(self.req, value, filename)
#
# elif url_dict['act'] == 'pdf':
# query = query_register()
# import opensipkd.base
......
import os
import colander
from datatables import (ColumnDT, DataTables, )
from deform import (widget, )
from opensipkd.tools.buttons import btn_close, btn_delete, btn_view
from opensipkd.tools.report import open_rml_row, csv_response, open_rml_pdf, pdf_response, file_response
from pyramid.i18n import TranslationStringFactory
from pyramid.view import view_config
from . import BaseView, button_import # Tombol import
from . import BaseView, button_import, get_params # Tombol import
from opensipkd.models import (DBSession, User, ExternalIdentity)
# lib buat mendapatkan full path asset
from pyramid.path import AssetResolver
_ = TranslationStringFactory('user')
......@@ -41,6 +46,11 @@ class UserExt(BaseView):
self.list_buttons = (btn_close,) + self.list_report + (button_import,)
self.table = ExternalIdentity
# Coba cetak pdf
path = os.path.dirname(__file__)
path = os.path.dirname(path)
self.report_file = os.path.join(path, 'reports', 'users-external.jrxml')
@view_config(
route_name='user-ext',
renderer='templates/table.pt',
......@@ -64,9 +74,60 @@ class UserExt(BaseView):
def view_delete(self):
return super(UserExt, self).view_delete()
# Mendapatkan path gambar
def get_module_path(self, module_name):
a = AssetResolver(module_name)
resolver = a.resolve('')
return resolver.abspath()
def pdf_response(self, **kwargs):
from opensipkd.base.tools.report import jasper_export
logo = self.get_module_path('opensipkd.base')
logo = os.path.join(logo, 'static', 'img', 'logo.png')
parameters = {
"judul": get_params('company', "openSIPKD"),
"logo": logo
}
print(parameters)
filename = jasper_export(self.report_file, parameters=parameters)
return file_response(self.req, filename=filename[0])
# Coba csv
def csv_response(self, **kwargs):
query = self.table.query_register()
row = query.first()
header = row._mapping.keys()
rows = [list(item) for item in query.all()]
filename = f"{get_random_string(16)}.csv"
value = {
'header': header,
'rows': rows,
}
return csv_response(self.req, value, filename)
def csv_response(request, value, filename=None):
if not filename:
filename = get_random_string(20)+".csv"
response = request.response
response.content_type = 'text/csv'
# response.content_disposition = 'attachment;filename=' + filename
response.content_disposition = 'filename=' + filename
if sys.version_info < (3,):
import StringIO
fout = StringIO.StringIO()
else:
fout = io.StringIO()
fcsv = csv.writer(fout, delimiter=',', quotechar='"',
quoting=csv.QUOTE_MINIMAL)
fcsv.writerow(value.get('header', []))
fcsv.writerows(value.get('rows', []))
response.write(fout.getvalue())
return response
@view_config(
route_name='user-ext-act',
renderer='json', permission='user-view')
renderer='json',
permission='user-view')
def view_act(self):
return super(UserExt, self).view_act()
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!