提交新项目

This commit is contained in:
kongyuebin
2019-12-19 14:47:58 +08:00
parent 7ba20ac1b9
commit f29066a984
609 changed files with 238892 additions and 0 deletions

15
jhboss/.idea/dataSources.local.xml generated Normal file
View File

@@ -0,0 +1,15 @@
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="dataSourceStorageLocal">
<data-source name="juhe_pay@localhost" uuid="7b527db8-3148-4910-95ac-f47d00a18ffa">
<database-info product="MySQL" version="5.6.42" jdbc-version="4.0" driver-name="MySQL Connector Java" driver-version="mysql-connector-java-5.1.35 ( Revision: 5fb9c5849535c13917c2cf9baaece6ef9693ef27 )">
<extra-name-characters>#@</extra-name-characters>
<identifier-quote-string>`</identifier-quote-string>
</database-info>
<case-sensitivity plain-identifiers="lower" quoted-identifiers="lower" />
<secret-storage>master_key</secret-storage>
<user-name>root</user-name>
<introspection-schemas>*:juhe_pay</introspection-schemas>
</data-source>
</component>
</project>

19
jhboss/.idea/dataSources.xml generated Normal file
View File

@@ -0,0 +1,19 @@
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="DataSourceManagerImpl" format="xml" multifile-model="true">
<data-source source="LOCAL" name="juhe_pay@localhost" uuid="7b527db8-3148-4910-95ac-f47d00a18ffa">
<driver-ref>mysql</driver-ref>
<synchronize>true</synchronize>
<jdbc-driver>com.mysql.jdbc.Driver</jdbc-driver>
<jdbc-url>jdbc:mysql://localhost:3306/juhe_pay</jdbc-url>
<driver-properties>
<property name="autoReconnect" value="true" />
<property name="zeroDateTimeBehavior" value="convertToNull" />
<property name="tinyInt1isBit" value="false" />
<property name="characterEncoding" value="utf8" />
<property name="characterSetResults" value="utf8" />
<property name="yearIsDateType" value="false" />
</driver-properties>
</data-source>
</component>
</project>

View File

@@ -0,0 +1,904 @@
<?xml version="1.0" encoding="UTF-8"?>
<dataSource name="juhe_pay@localhost">
<database-model serializer="dbm" rdbms="MYSQL" format-version="4.7">
<root id="1">
<DefaultCasing>lower/lower</DefaultCasing>
</root>
<schema id="2" parent="1" name="fast_pay">
<Collation>utf8_general_ci</Collation>
</schema>
<schema id="3" parent="1" name="information_schema">
<Collation>utf8_general_ci</Collation>
</schema>
<schema id="4" parent="1" name="juhe_pay">
<Current>1</Current>
<Visible>1</Visible>
<Collation>latin1_swedish_ci</Collation>
</schema>
<schema id="5" parent="1" name="mgtv_user">
<Collation>latin1_swedish_ci</Collation>
</schema>
<schema id="6" parent="1" name="mysql">
<Collation>latin1_swedish_ci</Collation>
</schema>
<schema id="7" parent="1" name="performance_schema">
<Collation>utf8_general_ci</Collation>
</schema>
<collation id="8" parent="1" name="armscii8_bin">
<Charset>armscii8</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="9" parent="1" name="armscii8_general_ci">
<Charset>armscii8</Charset>
<DefaultForCharset>1</DefaultForCharset>
</collation>
<collation id="10" parent="1" name="ascii_bin">
<Charset>ascii</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="11" parent="1" name="ascii_general_ci">
<Charset>ascii</Charset>
<DefaultForCharset>1</DefaultForCharset>
</collation>
<collation id="12" parent="1" name="big5_bin">
<Charset>big5</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="13" parent="1" name="big5_chinese_ci">
<Charset>big5</Charset>
<DefaultForCharset>1</DefaultForCharset>
</collation>
<collation id="14" parent="1" name="binary">
<Charset>binary</Charset>
<DefaultForCharset>1</DefaultForCharset>
</collation>
<collation id="15" parent="1" name="cp1250_bin">
<Charset>cp1250</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="16" parent="1" name="cp1250_croatian_ci">
<Charset>cp1250</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="17" parent="1" name="cp1250_czech_cs">
<Charset>cp1250</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="18" parent="1" name="cp1250_general_ci">
<Charset>cp1250</Charset>
<DefaultForCharset>1</DefaultForCharset>
</collation>
<collation id="19" parent="1" name="cp1250_polish_ci">
<Charset>cp1250</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="20" parent="1" name="cp1251_bin">
<Charset>cp1251</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="21" parent="1" name="cp1251_bulgarian_ci">
<Charset>cp1251</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="22" parent="1" name="cp1251_general_ci">
<Charset>cp1251</Charset>
<DefaultForCharset>1</DefaultForCharset>
</collation>
<collation id="23" parent="1" name="cp1251_general_cs">
<Charset>cp1251</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="24" parent="1" name="cp1251_ukrainian_ci">
<Charset>cp1251</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="25" parent="1" name="cp1256_bin">
<Charset>cp1256</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="26" parent="1" name="cp1256_general_ci">
<Charset>cp1256</Charset>
<DefaultForCharset>1</DefaultForCharset>
</collation>
<collation id="27" parent="1" name="cp1257_bin">
<Charset>cp1257</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="28" parent="1" name="cp1257_general_ci">
<Charset>cp1257</Charset>
<DefaultForCharset>1</DefaultForCharset>
</collation>
<collation id="29" parent="1" name="cp1257_lithuanian_ci">
<Charset>cp1257</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="30" parent="1" name="cp850_bin">
<Charset>cp850</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="31" parent="1" name="cp850_general_ci">
<Charset>cp850</Charset>
<DefaultForCharset>1</DefaultForCharset>
</collation>
<collation id="32" parent="1" name="cp852_bin">
<Charset>cp852</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="33" parent="1" name="cp852_general_ci">
<Charset>cp852</Charset>
<DefaultForCharset>1</DefaultForCharset>
</collation>
<collation id="34" parent="1" name="cp866_bin">
<Charset>cp866</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="35" parent="1" name="cp866_general_ci">
<Charset>cp866</Charset>
<DefaultForCharset>1</DefaultForCharset>
</collation>
<collation id="36" parent="1" name="cp932_bin">
<Charset>cp932</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="37" parent="1" name="cp932_japanese_ci">
<Charset>cp932</Charset>
<DefaultForCharset>1</DefaultForCharset>
</collation>
<collation id="38" parent="1" name="dec8_bin">
<Charset>dec8</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="39" parent="1" name="dec8_swedish_ci">
<Charset>dec8</Charset>
<DefaultForCharset>1</DefaultForCharset>
</collation>
<collation id="40" parent="1" name="eucjpms_bin">
<Charset>eucjpms</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="41" parent="1" name="eucjpms_japanese_ci">
<Charset>eucjpms</Charset>
<DefaultForCharset>1</DefaultForCharset>
</collation>
<collation id="42" parent="1" name="euckr_bin">
<Charset>euckr</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="43" parent="1" name="euckr_korean_ci">
<Charset>euckr</Charset>
<DefaultForCharset>1</DefaultForCharset>
</collation>
<collation id="44" parent="1" name="gb2312_bin">
<Charset>gb2312</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="45" parent="1" name="gb2312_chinese_ci">
<Charset>gb2312</Charset>
<DefaultForCharset>1</DefaultForCharset>
</collation>
<collation id="46" parent="1" name="gbk_bin">
<Charset>gbk</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="47" parent="1" name="gbk_chinese_ci">
<Charset>gbk</Charset>
<DefaultForCharset>1</DefaultForCharset>
</collation>
<collation id="48" parent="1" name="geostd8_bin">
<Charset>geostd8</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="49" parent="1" name="geostd8_general_ci">
<Charset>geostd8</Charset>
<DefaultForCharset>1</DefaultForCharset>
</collation>
<collation id="50" parent="1" name="greek_bin">
<Charset>greek</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="51" parent="1" name="greek_general_ci">
<Charset>greek</Charset>
<DefaultForCharset>1</DefaultForCharset>
</collation>
<collation id="52" parent="1" name="hebrew_bin">
<Charset>hebrew</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="53" parent="1" name="hebrew_general_ci">
<Charset>hebrew</Charset>
<DefaultForCharset>1</DefaultForCharset>
</collation>
<collation id="54" parent="1" name="hp8_bin">
<Charset>hp8</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="55" parent="1" name="hp8_english_ci">
<Charset>hp8</Charset>
<DefaultForCharset>1</DefaultForCharset>
</collation>
<collation id="56" parent="1" name="keybcs2_bin">
<Charset>keybcs2</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="57" parent="1" name="keybcs2_general_ci">
<Charset>keybcs2</Charset>
<DefaultForCharset>1</DefaultForCharset>
</collation>
<collation id="58" parent="1" name="koi8r_bin">
<Charset>koi8r</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="59" parent="1" name="koi8r_general_ci">
<Charset>koi8r</Charset>
<DefaultForCharset>1</DefaultForCharset>
</collation>
<collation id="60" parent="1" name="koi8u_bin">
<Charset>koi8u</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="61" parent="1" name="koi8u_general_ci">
<Charset>koi8u</Charset>
<DefaultForCharset>1</DefaultForCharset>
</collation>
<collation id="62" parent="1" name="latin1_bin">
<Charset>latin1</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="63" parent="1" name="latin1_danish_ci">
<Charset>latin1</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="64" parent="1" name="latin1_general_ci">
<Charset>latin1</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="65" parent="1" name="latin1_general_cs">
<Charset>latin1</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="66" parent="1" name="latin1_german1_ci">
<Charset>latin1</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="67" parent="1" name="latin1_german2_ci">
<Charset>latin1</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="68" parent="1" name="latin1_spanish_ci">
<Charset>latin1</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="69" parent="1" name="latin1_swedish_ci">
<Charset>latin1</Charset>
<DefaultForCharset>1</DefaultForCharset>
</collation>
<collation id="70" parent="1" name="latin2_bin">
<Charset>latin2</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="71" parent="1" name="latin2_croatian_ci">
<Charset>latin2</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="72" parent="1" name="latin2_czech_cs">
<Charset>latin2</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="73" parent="1" name="latin2_general_ci">
<Charset>latin2</Charset>
<DefaultForCharset>1</DefaultForCharset>
</collation>
<collation id="74" parent="1" name="latin2_hungarian_ci">
<Charset>latin2</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="75" parent="1" name="latin5_bin">
<Charset>latin5</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="76" parent="1" name="latin5_turkish_ci">
<Charset>latin5</Charset>
<DefaultForCharset>1</DefaultForCharset>
</collation>
<collation id="77" parent="1" name="latin7_bin">
<Charset>latin7</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="78" parent="1" name="latin7_estonian_cs">
<Charset>latin7</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="79" parent="1" name="latin7_general_ci">
<Charset>latin7</Charset>
<DefaultForCharset>1</DefaultForCharset>
</collation>
<collation id="80" parent="1" name="latin7_general_cs">
<Charset>latin7</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="81" parent="1" name="macce_bin">
<Charset>macce</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="82" parent="1" name="macce_general_ci">
<Charset>macce</Charset>
<DefaultForCharset>1</DefaultForCharset>
</collation>
<collation id="83" parent="1" name="macroman_bin">
<Charset>macroman</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="84" parent="1" name="macroman_general_ci">
<Charset>macroman</Charset>
<DefaultForCharset>1</DefaultForCharset>
</collation>
<collation id="85" parent="1" name="sjis_bin">
<Charset>sjis</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="86" parent="1" name="sjis_japanese_ci">
<Charset>sjis</Charset>
<DefaultForCharset>1</DefaultForCharset>
</collation>
<collation id="87" parent="1" name="swe7_bin">
<Charset>swe7</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="88" parent="1" name="swe7_swedish_ci">
<Charset>swe7</Charset>
<DefaultForCharset>1</DefaultForCharset>
</collation>
<collation id="89" parent="1" name="tis620_bin">
<Charset>tis620</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="90" parent="1" name="tis620_thai_ci">
<Charset>tis620</Charset>
<DefaultForCharset>1</DefaultForCharset>
</collation>
<collation id="91" parent="1" name="ucs2_bin">
<Charset>ucs2</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="92" parent="1" name="ucs2_croatian_ci">
<Charset>ucs2</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="93" parent="1" name="ucs2_czech_ci">
<Charset>ucs2</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="94" parent="1" name="ucs2_danish_ci">
<Charset>ucs2</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="95" parent="1" name="ucs2_esperanto_ci">
<Charset>ucs2</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="96" parent="1" name="ucs2_estonian_ci">
<Charset>ucs2</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="97" parent="1" name="ucs2_general_ci">
<Charset>ucs2</Charset>
<DefaultForCharset>1</DefaultForCharset>
</collation>
<collation id="98" parent="1" name="ucs2_general_mysql500_ci">
<Charset>ucs2</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="99" parent="1" name="ucs2_german2_ci">
<Charset>ucs2</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="100" parent="1" name="ucs2_hungarian_ci">
<Charset>ucs2</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="101" parent="1" name="ucs2_icelandic_ci">
<Charset>ucs2</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="102" parent="1" name="ucs2_latvian_ci">
<Charset>ucs2</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="103" parent="1" name="ucs2_lithuanian_ci">
<Charset>ucs2</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="104" parent="1" name="ucs2_persian_ci">
<Charset>ucs2</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="105" parent="1" name="ucs2_polish_ci">
<Charset>ucs2</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="106" parent="1" name="ucs2_roman_ci">
<Charset>ucs2</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="107" parent="1" name="ucs2_romanian_ci">
<Charset>ucs2</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="108" parent="1" name="ucs2_sinhala_ci">
<Charset>ucs2</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="109" parent="1" name="ucs2_slovak_ci">
<Charset>ucs2</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="110" parent="1" name="ucs2_slovenian_ci">
<Charset>ucs2</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="111" parent="1" name="ucs2_spanish2_ci">
<Charset>ucs2</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="112" parent="1" name="ucs2_spanish_ci">
<Charset>ucs2</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="113" parent="1" name="ucs2_swedish_ci">
<Charset>ucs2</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="114" parent="1" name="ucs2_turkish_ci">
<Charset>ucs2</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="115" parent="1" name="ucs2_unicode_520_ci">
<Charset>ucs2</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="116" parent="1" name="ucs2_unicode_ci">
<Charset>ucs2</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="117" parent="1" name="ucs2_vietnamese_ci">
<Charset>ucs2</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="118" parent="1" name="ujis_bin">
<Charset>ujis</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="119" parent="1" name="ujis_japanese_ci">
<Charset>ujis</Charset>
<DefaultForCharset>1</DefaultForCharset>
</collation>
<collation id="120" parent="1" name="utf16_bin">
<Charset>utf16</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="121" parent="1" name="utf16_croatian_ci">
<Charset>utf16</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="122" parent="1" name="utf16_czech_ci">
<Charset>utf16</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="123" parent="1" name="utf16_danish_ci">
<Charset>utf16</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="124" parent="1" name="utf16_esperanto_ci">
<Charset>utf16</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="125" parent="1" name="utf16_estonian_ci">
<Charset>utf16</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="126" parent="1" name="utf16_general_ci">
<Charset>utf16</Charset>
<DefaultForCharset>1</DefaultForCharset>
</collation>
<collation id="127" parent="1" name="utf16_german2_ci">
<Charset>utf16</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="128" parent="1" name="utf16_hungarian_ci">
<Charset>utf16</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="129" parent="1" name="utf16_icelandic_ci">
<Charset>utf16</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="130" parent="1" name="utf16_latvian_ci">
<Charset>utf16</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="131" parent="1" name="utf16_lithuanian_ci">
<Charset>utf16</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="132" parent="1" name="utf16_persian_ci">
<Charset>utf16</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="133" parent="1" name="utf16_polish_ci">
<Charset>utf16</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="134" parent="1" name="utf16_roman_ci">
<Charset>utf16</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="135" parent="1" name="utf16_romanian_ci">
<Charset>utf16</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="136" parent="1" name="utf16_sinhala_ci">
<Charset>utf16</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="137" parent="1" name="utf16_slovak_ci">
<Charset>utf16</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="138" parent="1" name="utf16_slovenian_ci">
<Charset>utf16</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="139" parent="1" name="utf16_spanish2_ci">
<Charset>utf16</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="140" parent="1" name="utf16_spanish_ci">
<Charset>utf16</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="141" parent="1" name="utf16_swedish_ci">
<Charset>utf16</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="142" parent="1" name="utf16_turkish_ci">
<Charset>utf16</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="143" parent="1" name="utf16_unicode_520_ci">
<Charset>utf16</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="144" parent="1" name="utf16_unicode_ci">
<Charset>utf16</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="145" parent="1" name="utf16_vietnamese_ci">
<Charset>utf16</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="146" parent="1" name="utf16le_bin">
<Charset>utf16le</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="147" parent="1" name="utf16le_general_ci">
<Charset>utf16le</Charset>
<DefaultForCharset>1</DefaultForCharset>
</collation>
<collation id="148" parent="1" name="utf32_bin">
<Charset>utf32</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="149" parent="1" name="utf32_croatian_ci">
<Charset>utf32</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="150" parent="1" name="utf32_czech_ci">
<Charset>utf32</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="151" parent="1" name="utf32_danish_ci">
<Charset>utf32</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="152" parent="1" name="utf32_esperanto_ci">
<Charset>utf32</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="153" parent="1" name="utf32_estonian_ci">
<Charset>utf32</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="154" parent="1" name="utf32_general_ci">
<Charset>utf32</Charset>
<DefaultForCharset>1</DefaultForCharset>
</collation>
<collation id="155" parent="1" name="utf32_german2_ci">
<Charset>utf32</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="156" parent="1" name="utf32_hungarian_ci">
<Charset>utf32</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="157" parent="1" name="utf32_icelandic_ci">
<Charset>utf32</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="158" parent="1" name="utf32_latvian_ci">
<Charset>utf32</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="159" parent="1" name="utf32_lithuanian_ci">
<Charset>utf32</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="160" parent="1" name="utf32_persian_ci">
<Charset>utf32</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="161" parent="1" name="utf32_polish_ci">
<Charset>utf32</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="162" parent="1" name="utf32_roman_ci">
<Charset>utf32</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="163" parent="1" name="utf32_romanian_ci">
<Charset>utf32</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="164" parent="1" name="utf32_sinhala_ci">
<Charset>utf32</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="165" parent="1" name="utf32_slovak_ci">
<Charset>utf32</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="166" parent="1" name="utf32_slovenian_ci">
<Charset>utf32</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="167" parent="1" name="utf32_spanish2_ci">
<Charset>utf32</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="168" parent="1" name="utf32_spanish_ci">
<Charset>utf32</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="169" parent="1" name="utf32_swedish_ci">
<Charset>utf32</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="170" parent="1" name="utf32_turkish_ci">
<Charset>utf32</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="171" parent="1" name="utf32_unicode_520_ci">
<Charset>utf32</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="172" parent="1" name="utf32_unicode_ci">
<Charset>utf32</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="173" parent="1" name="utf32_vietnamese_ci">
<Charset>utf32</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="174" parent="1" name="utf8_bin">
<Charset>utf8</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="175" parent="1" name="utf8_croatian_ci">
<Charset>utf8</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="176" parent="1" name="utf8_czech_ci">
<Charset>utf8</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="177" parent="1" name="utf8_danish_ci">
<Charset>utf8</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="178" parent="1" name="utf8_esperanto_ci">
<Charset>utf8</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="179" parent="1" name="utf8_estonian_ci">
<Charset>utf8</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="180" parent="1" name="utf8_general_ci">
<Charset>utf8</Charset>
<DefaultForCharset>1</DefaultForCharset>
</collation>
<collation id="181" parent="1" name="utf8_general_mysql500_ci">
<Charset>utf8</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="182" parent="1" name="utf8_german2_ci">
<Charset>utf8</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="183" parent="1" name="utf8_hungarian_ci">
<Charset>utf8</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="184" parent="1" name="utf8_icelandic_ci">
<Charset>utf8</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="185" parent="1" name="utf8_latvian_ci">
<Charset>utf8</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="186" parent="1" name="utf8_lithuanian_ci">
<Charset>utf8</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="187" parent="1" name="utf8_persian_ci">
<Charset>utf8</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="188" parent="1" name="utf8_polish_ci">
<Charset>utf8</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="189" parent="1" name="utf8_roman_ci">
<Charset>utf8</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="190" parent="1" name="utf8_romanian_ci">
<Charset>utf8</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="191" parent="1" name="utf8_sinhala_ci">
<Charset>utf8</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="192" parent="1" name="utf8_slovak_ci">
<Charset>utf8</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="193" parent="1" name="utf8_slovenian_ci">
<Charset>utf8</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="194" parent="1" name="utf8_spanish2_ci">
<Charset>utf8</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="195" parent="1" name="utf8_spanish_ci">
<Charset>utf8</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="196" parent="1" name="utf8_swedish_ci">
<Charset>utf8</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="197" parent="1" name="utf8_turkish_ci">
<Charset>utf8</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="198" parent="1" name="utf8_unicode_520_ci">
<Charset>utf8</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="199" parent="1" name="utf8_unicode_ci">
<Charset>utf8</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="200" parent="1" name="utf8_vietnamese_ci">
<Charset>utf8</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="201" parent="1" name="utf8mb4_bin">
<Charset>utf8mb4</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="202" parent="1" name="utf8mb4_croatian_ci">
<Charset>utf8mb4</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="203" parent="1" name="utf8mb4_czech_ci">
<Charset>utf8mb4</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="204" parent="1" name="utf8mb4_danish_ci">
<Charset>utf8mb4</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="205" parent="1" name="utf8mb4_esperanto_ci">
<Charset>utf8mb4</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="206" parent="1" name="utf8mb4_estonian_ci">
<Charset>utf8mb4</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="207" parent="1" name="utf8mb4_general_ci">
<Charset>utf8mb4</Charset>
<DefaultForCharset>1</DefaultForCharset>
</collation>
<collation id="208" parent="1" name="utf8mb4_german2_ci">
<Charset>utf8mb4</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="209" parent="1" name="utf8mb4_hungarian_ci">
<Charset>utf8mb4</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="210" parent="1" name="utf8mb4_icelandic_ci">
<Charset>utf8mb4</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="211" parent="1" name="utf8mb4_latvian_ci">
<Charset>utf8mb4</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="212" parent="1" name="utf8mb4_lithuanian_ci">
<Charset>utf8mb4</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="213" parent="1" name="utf8mb4_persian_ci">
<Charset>utf8mb4</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="214" parent="1" name="utf8mb4_polish_ci">
<Charset>utf8mb4</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="215" parent="1" name="utf8mb4_roman_ci">
<Charset>utf8mb4</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="216" parent="1" name="utf8mb4_romanian_ci">
<Charset>utf8mb4</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="217" parent="1" name="utf8mb4_sinhala_ci">
<Charset>utf8mb4</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="218" parent="1" name="utf8mb4_slovak_ci">
<Charset>utf8mb4</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="219" parent="1" name="utf8mb4_slovenian_ci">
<Charset>utf8mb4</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="220" parent="1" name="utf8mb4_spanish2_ci">
<Charset>utf8mb4</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="221" parent="1" name="utf8mb4_spanish_ci">
<Charset>utf8mb4</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="222" parent="1" name="utf8mb4_swedish_ci">
<Charset>utf8mb4</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="223" parent="1" name="utf8mb4_turkish_ci">
<Charset>utf8mb4</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="224" parent="1" name="utf8mb4_unicode_520_ci">
<Charset>utf8mb4</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="225" parent="1" name="utf8mb4_unicode_ci">
<Charset>utf8mb4</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
<collation id="226" parent="1" name="utf8mb4_vietnamese_ci">
<Charset>utf8mb4</Charset>
<DefaultForCharset>0</DefaultForCharset>
</collation>
</database-model>
</dataSource>

8
jhboss/.idea/jhboss.iml generated Normal file
View File

@@ -0,0 +1,8 @@
<?xml version="1.0" encoding="UTF-8"?>
<module type="WEB_MODULE" version="4">
<component name="NewModuleRootManager">
<content url="file://$MODULE_DIR$" />
<orderEntry type="inheritedJdk" />
<orderEntry type="sourceFolder" forTests="false" />
</component>
</module>

6
jhboss/.idea/misc.xml generated Normal file
View File

@@ -0,0 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="JavaScriptSettings">
<option name="languageLevel" value="ES6" />
</component>
</project>

8
jhboss/.idea/modules.xml generated Normal file
View File

@@ -0,0 +1,8 @@
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="ProjectModuleManager">
<modules>
<module fileurl="file://$PROJECT_DIR$/.idea/jhboss.iml" filepath="$PROJECT_DIR$/.idea/jhboss.iml" />
</modules>
</component>
</project>

29
jhboss/.idea/watcherTasks.xml generated Normal file
View File

@@ -0,0 +1,29 @@
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="ProjectTasksOptions">
<TaskOptions isEnabled="true">
<option name="arguments" value="fmt $FilePath$" />
<option name="checkSyntaxErrors" value="true" />
<option name="description" />
<option name="exitCodeBehavior" value="ERROR" />
<option name="fileExtension" value="go" />
<option name="immediateSync" value="false" />
<option name="name" value="go fmt" />
<option name="output" value="$FilePath$" />
<option name="outputFilters">
<array />
</option>
<option name="outputFromStdout" value="false" />
<option name="program" value="$GoExecPath$" />
<option name="runOnExternalChanges" value="false" />
<option name="scopeName" value="Open Files" />
<option name="trackOnlyRoot" value="true" />
<option name="workingDir" value="" />
<envs>
<env name="GOROOT" value="$GOROOT$" />
<env name="GOPATH" value="$GOPATH$" />
<env name="PATH" value="$GoBinDirs$" />
</envs>
</TaskOptions>
</component>
</project>

695
jhboss/.idea/workspace.xml generated Normal file
View File

@@ -0,0 +1,695 @@
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="ChangeListManager">
<list default="true" id="02c02b32-d5b9-4207-ac4e-a00dd10068fe" name="Default" comment="" />
<option name="EXCLUDED_CONVERTED_TO_IGNORED" value="true" />
<option name="TRACKING_ENABLED" value="true" />
<option name="SHOW_DIALOG" value="false" />
<option name="HIGHLIGHT_CONFLICTS" value="true" />
<option name="HIGHLIGHT_NON_ACTIVE_CHANGELIST" value="false" />
<option name="LAST_RESOLUTION" value="IGNORE" />
</component>
<component name="DatabaseView">
<option name="SHOW_INTERMEDIATE" value="true" />
<option name="GROUP_DATA_SOURCES" value="true" />
<option name="GROUP_SCHEMA" value="true" />
<option name="GROUP_CONTENTS" value="false" />
<option name="SORT_POSITIONED" value="false" />
<option name="SHOW_EMPTY_GROUPS" value="false" />
<option name="AUTO_SCROLL_FROM_SOURCE" value="false" />
<option name="HIDDEN_KINDS">
<set />
</option>
<expand />
<select />
</component>
<component name="ExportToHTMLSettings">
<option name="OUTPUT_DIRECTORY" value="C:\gopath\src\jhboss\exportToHTML" />
</component>
<component name="FileEditorManager">
<leaf SIDE_TABS_SIZE_LIMIT_KEY="300">
<file leaf-file-name="login.go" pinned="false" current-in-tab="true">
<entry file="file://$PROJECT_DIR$/controllers/login.go">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="112">
<caret line="8" column="19" selection-start-line="8" selection-start-column="19" selection-end-line="8" selection-end-column="19" />
</state>
</provider>
</entry>
</file>
<file leaf-file-name="main.go" pinned="false" current-in-tab="false">
<entry file="file://$PROJECT_DIR$/main.go">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="70">
<caret line="5" column="16" selection-start-line="5" selection-start-column="16" selection-end-line="5" selection-end-column="16" />
</state>
</provider>
</entry>
</file>
</leaf>
</component>
<component name="FileTemplateManagerImpl">
<option name="RECENT_TEMPLATES">
<list>
<option value="JavaScript File" />
<option value="HTML File" />
<option value="Go File" />
</list>
</option>
</component>
<component name="FindInProjectRecents">
<findStrings>
<find>container</find>
<find>section</find>
<find>SessionCookieLifeTime</find>
<find>CookieLifeTime</find>
<find>Controller</find>
<find>assets/stylesheets</find>
<find>assets/javascripts</find>
<find>images</find>
<find>验证码失效!</find>
<find>GetSecondMenuInfoByMenuOrder</find>
<find>strings</find>
<find>UpdatePowerInfo</find>
<find>/edit/operator</find>
<find>/get/all/roll/pool</find>
<find>DeleteAccount</find>
<find>AddAgent</find>
<find>/add/agent</find>
<find>jhboss/</find>
<find>HOST</find>
<find>/jhboss</find>
<find>/jhboss/</find>
</findStrings>
<replaceStrings>
<replace />
<replace>../static/js</replace>
<replace>img</replace>
</replaceStrings>
<dirStrings>
<dir>C:\gopath\src\github.com</dir>
<dir>C:\gopath\src\github.com\astaxie\beego</dir>
<dir>C:\gopath\src\jhboss\views</dir>
<dir>C:\gopath\src\jhboss\static\css\plugins\bootstrap_colorpicker</dir>
<dir>C:\gopath\src\jhboss</dir>
</dirStrings>
</component>
<component name="GOROOT" path="C:\Go" />
<component name="IdeDocumentHistory">
<option name="CHANGED_PATHS">
<list>
<option value="$PROJECT_DIR$/controllers/show.go" />
<option value="$PROJECT_DIR$/views/text.html" />
<option value="$PROJECT_DIR$/controllers/base_controller.go" />
<option value="$PROJECT_DIR$/models/second_menu_info.go" />
<option value="$PROJECT_DIR$/models/power_info.go" />
<option value="$PROJECT_DIR$/models/menu_info.go" />
<option value="$PROJECT_DIR$/controllers/login.go" />
<option value="$PROJECT_DIR$/models/role_info.go" />
<option value="$PROJECT_DIR$/models/user_info.go" />
<option value="$PROJECT_DIR$/models/bank_card_info.go" />
<option value="$PROJECT_DIR$/controllers/test.go" />
<option value="$PROJECT_DIR$/conf/app.conf" />
<option value="$PROJECT_DIR$/models/road_info.go" />
<option value="$PROJECT_DIR$/models/road_pool_info.go" />
<option value="$PROJECT_DIR$/models/merchant_deploy_info.go" />
<option value="$PROJECT_DIR$/models/account.go" />
<option value="$PROJECT_DIR$/consts/consts.go" />
<option value="$PROJECT_DIR$/models/account_history.go" />
<option value="$PROJECT_DIR$/models/init.go" />
<option value="$PROJECT_DIR$/models/transaction.go" />
<option value="$PROJECT_DIR$/models/account_history_info.go" />
<option value="$PROJECT_DIR$/tools/mysql.sql" />
<option value="$PROJECT_DIR$/models/merchant_info.go" />
<option value="$PROJECT_DIR$/controllers/datas.go" />
<option value="$PROJECT_DIR$/controllers/get.go" />
<option value="$PROJECT_DIR$/controllers/add.go" />
<option value="$PROJECT_DIR$/models/agent_info.go" />
<option value="$PROJECT_DIR$/controllers/delete.go" />
<option value="$PROJECT_DIR$/controllers/update.go" />
<option value="$PROJECT_DIR$/views/main.html" />
<option value="$PROJECT_DIR$/views/menu.html" />
<option value="$PROJECT_DIR$/views/road_profit.html" />
<option value="$PROJECT_DIR$/routers/router.go" />
<option value="$PROJECT_DIR$/static/js/filter.js" />
<option value="$PROJECT_DIR$/views/account.html" />
<option value="$PROJECT_DIR$/views/account_history.html" />
<option value="$PROJECT_DIR$/views/bank_card.html" />
<option value="$PROJECT_DIR$/views/create_agent.html" />
<option value="$PROJECT_DIR$/views/edit_role.html" />
<option value="$PROJECT_DIR$/views/first_menu.html" />
<option value="$PROJECT_DIR$/views/merchant.html" />
<option value="$PROJECT_DIR$/views/power.html" />
<option value="$PROJECT_DIR$/views/road.html" />
<option value="$PROJECT_DIR$/views/road_pool.html" />
<option value="$PROJECT_DIR$/views/role.html" />
<option value="$PROJECT_DIR$/views/second_menu.html" />
<option value="$PROJECT_DIR$/controllers/page_controller.go" />
<option value="$PROJECT_DIR$/routers/router_pages.go" />
<option value="$PROJECT_DIR$/views/operator.html" />
<option value="$PROJECT_DIR$/views/login.html" />
<option value="$PROJECT_DIR$/views/index.html" />
</list>
</option>
</component>
<component name="JsBuildToolGruntFileManager" detection-done="true" sorting="DEFINITION_ORDER" />
<component name="JsBuildToolPackageJson" detection-done="true" sorting="DEFINITION_ORDER" />
<component name="JsGulpfileManager">
<detection-done>true</detection-done>
<sorting>DEFINITION_ORDER</sorting>
</component>
<component name="ProjectFrameBounds" extendedState="6">
<option name="x" value="3062" />
<option name="y" value="183" />
<option name="width" value="202" />
<option name="height" value="56" />
</component>
<component name="ProjectView">
<navigator proportions="" version="1">
<foldersAlwaysOnTop value="true" />
</navigator>
<panes>
<pane id="ProjectPane">
<subPane>
<expand>
<path>
<item name="jhboss" type="b2602c69:ProjectViewProjectNode" />
<item name="jhboss" type="462c0819:PsiDirectoryNode" />
</path>
</expand>
<select />
</subPane>
</pane>
<pane id="Scope" />
</panes>
</component>
<component name="PropertiesComponent">
<property name="DefaultGoTemplateProperty" value="Go File" />
<property name="DefaultHtmlFileTemplate" value="HTML File" />
<property name="NewWatcherDialog.advanced.open" value="true" />
<property name="com.intellij.database.dataSource.DataSourceTemplate" value="MySQL" />
<property name="go.gopath.indexing.explicitly.defined" value="true" />
<property name="go.sdk.automatically.set" value="true" />
<property name="last_opened_file_path" value="$PROJECT_DIR$/../recharge" />
<property name="nodejs_interpreter_path.stuck_in_default_project" value="undefined stuck path" />
<property name="nodejs_npm_path_reset_for_default_project" value="true" />
<property name="settings.editor.selected.configurable" value="xpath.settings" />
</component>
<component name="RecentsManager">
<key name="CopyFile.RECENT_KEYS">
<recent name="C:\gopath\src\jhboss\views" />
<recent name="C:\gopath\src\jhboss\static" />
<recent name="C:\gopath\src\jhboss\static\css" />
<recent name="C:\gopath\src\jhboss\static\img" />
<recent name="C:\gopath\src\jhboss\static\js" />
</key>
</component>
<component name="RunDashboard">
<option name="ruleStates">
<list>
<RuleState>
<option name="name" value="ConfigurationTypeDashboardGroupingRule" />
</RuleState>
<RuleState>
<option name="name" value="StatusDashboardGroupingRule" />
</RuleState>
</list>
</option>
</component>
<component name="RunManager">
<configuration name="go build" type="GoApplicationRunConfiguration" factoryName="Go Application">
<module name="jhboss" />
<working_directory value="$PROJECT_DIR$/" />
<go_parameters value="-i" />
<kind value="FILE" />
<filePath value="C:\gopath\src\jhboss\main.go" />
<package value="jhboss" />
<directory value="$PROJECT_DIR$/" />
</configuration>
</component>
<component name="TodoView">
<todo-panel id="selected-file">
<is-autoscroll-to-source value="true" />
</todo-panel>
<todo-panel id="all">
<are-packages-shown value="true" />
<is-autoscroll-to-source value="true" />
</todo-panel>
</component>
<component name="ToolWindowManager">
<frame x="1912" y="-8" width="1936" height="1066" extended-state="6" />
<layout>
<window_info content_ui="combo" id="Project" order="0" visible="true" weight="0.20127796" />
<window_info anchor="bottom" id="TODO" order="6" weight="0.32903227" />
<window_info anchor="bottom" id="Event Log" order="10" side_tool="true" weight="0.32903227" />
<window_info anchor="right" id="Database" order="3" />
<window_info anchor="bottom" id="Find" order="1" />
<window_info anchor="bottom" id="Database Changes" order="7" show_stripe_button="false" />
<window_info anchor="bottom" id="Version Control" order="9" show_stripe_button="false" />
<window_info anchor="bottom" id="Run" order="2" weight="0.32903227" />
<window_info id="Structure" order="1" side_tool="true" weight="0.25" />
<window_info active="true" anchor="bottom" id="Terminal" order="8" visible="true" weight="0.28172043" />
<window_info id="Favorites" order="2" side_tool="true" />
<window_info anchor="bottom" id="Debug" order="3" weight="0.5043011" />
<window_info anchor="right" content_ui="combo" id="Hierarchy" order="2" weight="0.25" />
<window_info anchor="bottom" id="Inspection" order="5" weight="0.4" />
<window_info anchor="right" id="Commander" internal_type="SLIDING" order="0" type="SLIDING" weight="0.4" />
<window_info anchor="right" id="Ant Build" order="1" weight="0.25" />
<window_info anchor="bottom" id="Message" order="0" />
<window_info anchor="bottom" id="Cvs" order="4" weight="0.25" />
</layout>
<layout-to-restore>
<window_info anchor="right" content_ui="combo" id="Hierarchy" order="2" weight="0.25" />
<window_info anchor="bottom" id="Inspection" order="5" weight="0.4" />
<window_info active="true" content_ui="combo" id="Project" order="0" visible="true" weight="0.20127796" />
<window_info id="Structure" order="1" side_tool="true" weight="0.25" />
<window_info anchor="right" id="Commander" internal_type="SLIDING" order="0" type="SLIDING" weight="0.4" />
<window_info anchor="right" id="Ant Build" order="1" weight="0.25" />
<window_info anchor="bottom" id="TODO" order="6" weight="0.32903227" />
<window_info anchor="bottom" id="Version Control" order="9" show_stripe_button="false" />
<window_info anchor="bottom" id="Run" order="2" weight="0.32903227" />
<window_info anchor="bottom" id="Message" order="0" />
<window_info anchor="bottom" id="Debug" order="3" weight="0.5043011" />
<window_info anchor="right" id="Database" order="3" />
<window_info anchor="bottom" id="Terminal" order="8" weight="0.28172043" />
<window_info anchor="bottom" id="Event Log" order="10" side_tool="true" weight="0.32903227" />
<window_info anchor="bottom" id="Database Changes" order="7" show_stripe_button="false" />
<window_info anchor="bottom" id="Cvs" order="4" weight="0.25" />
<window_info anchor="bottom" id="Find" order="1" />
<window_info id="Favorites" order="2" side_tool="true" />
</layout-to-restore>
</component>
<component name="TypeScriptGeneratedFilesManager">
<option name="version" value="1" />
</component>
<component name="VcsContentAnnotationSettings">
<option name="myLimit" value="2678400000" />
</component>
<component name="XDebuggerManager">
<breakpoint-manager>
<breakpoints>
<line-breakpoint enabled="true" type="DlvLineBreakpoint">
<url>file://$PROJECT_DIR$/../github.com/astaxie/beego/validation/validators.go</url>
<line>397</line>
<option name="timeStamp" value="8" />
</line-breakpoint>
<line-breakpoint enabled="true" type="DlvLineBreakpoint">
<url>file://$PROJECT_DIR$/controllers/get.go</url>
<line>607</line>
<option name="timeStamp" value="112" />
</line-breakpoint>
</breakpoints>
<option name="time" value="114" />
</breakpoint-manager>
</component>
<component name="editorHistoryManager">
<entry file="file://$PROJECT_DIR$/../github.com/astaxie/beego/router.go">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="192">
<caret line="719" selection-start-line="719" selection-end-line="719" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/models/role_info.go">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="-654">
<caret line="19" column="12" selection-start-line="19" selection-start-column="12" selection-end-line="19" selection-end-column="12" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/models/second_menu_info.go">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="546">
<caret line="139" column="35" selection-start-line="139" selection-start-column="23" selection-end-line="139" selection-end-column="35" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/conf/app.conf">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="14">
<caret line="1" column="15" selection-start-line="1" selection-start-column="15" selection-end-line="1" selection-end-column="15" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/models/menu_info.go">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="1768">
<caret line="149" column="7" selection-start-line="149" selection-start-column="7" selection-end-line="149" selection-end-column="7" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/models/road_pool_info.go">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="1414">
<caret line="104" column="23" selection-start-line="104" selection-start-column="23" selection-end-line="104" selection-end-column="23" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/models/merchant_deploy_info.go">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="158">
<caret line="26" column="16" selection-start-line="26" selection-start-column="4" selection-end-line="26" selection-end-column="16" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/models/road_info.go">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="14">
<caret line="66" column="15" selection-start-line="66" selection-start-column="15" selection-end-line="66" selection-end-column="15" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/models/account_history.go" />
<entry file="file://$PROJECT_DIR$/models/transaction.go">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="350">
<caret line="30" column="37" selection-start-line="30" selection-start-column="37" selection-end-line="30" selection-end-column="37" />
<folding>
<element signature="e#322#430#0" expanded="true" />
</folding>
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/tools/mysql.sql">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="193">
<caret line="179" column="51" selection-start-line="179" selection-start-column="51" selection-end-line="179" selection-end-column="51" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/models/account_history_info.go">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="260">
<caret line="49" column="35" selection-start-line="49" selection-start-column="35" selection-end-line="49" selection-end-column="35" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/models/merchant_info.go">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="280">
<caret line="55" selection-start-line="55" selection-end-line="55" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/models/account.go">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="1134">
<caret line="86" column="6" selection-start-line="86" selection-start-column="6" selection-end-line="86" selection-end-column="6" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/controllers/datas.go">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="2338">
<caret line="169" column="35" selection-start-line="169" selection-start-column="35" selection-end-line="169" selection-end-column="35" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/models/agent_info.go">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="512">
<caret line="126" column="15" selection-start-line="126" selection-start-column="15" selection-end-line="126" selection-end-column="15" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/controllers/update.go">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="5754">
<caret line="418" column="61" selection-start-line="418" selection-start-column="61" selection-end-line="418" selection-end-column="61" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/controllers/get.go">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="8624">
<caret line="654" column="20" selection-start-line="654" selection-start-column="20" selection-end-line="654" selection-end-column="20" />
<folding>
<element signature="n#!!block;n#GetOneMerchant#0" />
<element signature="n#!!block;n#GetOneMerchantDeploy#0" />
</folding>
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/consts/consts.go">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="280">
<caret line="20" selection-start-line="20" selection-end-line="20" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/static/js/basic.js">
<provider selected="true" editor-type-id="text-editor" />
</entry>
<entry file="file://$PROJECT_DIR$/controllers/add.go">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="182">
<caret line="23" selection-start-line="23" selection-end-line="25" selection-end-column="1" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/controllers/test.go">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="190">
<caret line="26" column="31" selection-start-line="26" selection-start-column="31" selection-end-line="26" selection-end-column="31" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/controllers/base_controller.go">
<provider selected="true" editor-type-id="text-editor" />
</entry>
<entry file="file://$PROJECT_DIR$/routers/router.go">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="126">
<caret line="9" column="12" selection-start-line="9" selection-start-column="12" selection-end-line="9" selection-end-column="12" />
<folding>
<element signature="e#17#77#0" expanded="true" />
</folding>
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/views/account.html">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="198">
<caret line="328" column="16" selection-start-line="328" selection-start-column="16" selection-end-line="328" selection-end-column="16" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/views/edit_role.html">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="198">
<caret line="148" column="20" selection-start-line="148" selection-start-column="20" selection-end-line="148" selection-end-column="20" />
<folding>
<element signature="n#style#0;n#span#0;n#!!top" expanded="true" />
</folding>
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/views/create_agent.html">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="198">
<caret line="446" column="21" selection-start-line="446" selection-start-column="21" selection-end-line="446" selection-end-column="21" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/views/bank_card.html">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="198">
<caret line="440" column="21" selection-start-line="440" selection-start-column="21" selection-end-line="440" selection-end-column="21" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/views/account_history.html">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="198">
<caret line="151" column="16" selection-start-line="151" selection-start-column="16" selection-end-line="151" selection-end-column="16" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/static/js/filter.js">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="14">
<caret line="1" lean-forward="true" selection-start-line="1" selection-end-line="1" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/views/first_menu.html">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="198">
<caret line="153" column="35" selection-start-line="153" selection-start-column="31" selection-end-line="153" selection-end-column="35" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/views/main.html">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="42">
<caret line="3" column="6" lean-forward="true" selection-start-line="3" selection-start-column="6" selection-end-line="3" selection-end-column="6" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/views/menu.html">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="198">
<caret line="21" column="42" selection-start-line="21" selection-start-column="42" selection-end-line="21" selection-end-column="42" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/views/merchant.html">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="198">
<caret line="1147" column="21" selection-start-line="1147" selection-start-column="21" selection-end-line="1147" selection-end-column="21" />
<folding>
<element signature="n#style#0;n#input#0;n#!!top" expanded="true" />
<element signature="n#style#0;n#input#0;n#!!top" expanded="true" />
<element signature="n#style#0;n#input#0;n#!!top" expanded="true" />
<element signature="n#style#0;n#input#0;n#!!top" expanded="true" />
</folding>
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/views/second_menu.html">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="227">
<caret line="174" column="41" selection-start-line="174" selection-start-column="37" selection-end-line="174" selection-end-column="41" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/views/role.html">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="198">
<caret line="126" column="39" selection-start-line="126" selection-start-column="35" selection-end-line="126" selection-end-column="39" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/views/road_profit.html">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="70">
<caret line="5" column="23" lean-forward="true" selection-start-line="5" selection-start-column="23" selection-end-line="5" selection-end-column="23" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/views/road_pool.html">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="198">
<caret line="567" column="20" selection-start-line="567" selection-start-column="20" selection-end-line="567" selection-end-column="20" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/views/road.html">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="198">
<caret line="479" column="25" selection-start-line="479" selection-start-column="25" selection-end-line="479" selection-end-column="25" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/views/power.html">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="198">
<caret line="139" column="39" selection-start-line="139" selection-start-column="35" selection-end-line="139" selection-end-column="39" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/models/init.go">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="266">
<caret line="19" column="6" selection-start-line="19" selection-start-column="6" selection-end-line="19" selection-end-column="6" />
<folding>
<element signature="e#311#424#0" expanded="true" />
</folding>
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/controllers/delete.go">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="182">
<caret line="13" column="5" selection-start-line="13" selection-start-column="5" selection-end-line="13" selection-end-column="5" />
<folding>
<element signature="n#!!block;n#DeleteRoad#0" />
<element signature="n#!!block;n#DeleteRoadPool#0" />
<element signature="n#!!block;n#DeleteMerchant#0" />
</folding>
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/static/js/jquery.min.js">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="215">
<caret line="3" column="10264" selection-start-line="3" selection-start-column="10264" selection-end-line="3" selection-end-column="10264" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/views/operator.html">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="212">
<caret line="265" column="29" selection-start-line="265" selection-start-column="29" selection-end-line="265" selection-end-column="29" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/routers/router_pages.go">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="392">
<caret line="28" column="68" selection-start-line="28" selection-start-column="68" selection-end-line="28" selection-end-column="68" />
<folding>
<element signature="e#324#384#0" expanded="true" />
</folding>
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/controllers/page_controller.go">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="208">
<caret line="62" column="34" selection-start-line="62" selection-start-column="34" selection-end-line="62" selection-end-column="34" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/jhboss.log">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="215">
<caret line="25" column="81" selection-start-line="25" selection-start-column="81" selection-end-line="25" selection-end-column="81" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/views/index.html">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="1485">
<caret line="292" column="44" selection-start-line="292" selection-start-column="44" selection-end-line="292" selection-end-column="44" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/views/login.html">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="645">
<caret line="111" column="50" selection-start-line="111" selection-start-column="50" selection-end-line="111" selection-end-column="50" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/main.go">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="70">
<caret line="5" column="16" selection-start-line="5" selection-start-column="16" selection-end-line="5" selection-end-column="16" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/controllers/login.go">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="112">
<caret line="8" column="19" selection-start-line="8" selection-start-column="19" selection-end-line="8" selection-end-column="19" />
</state>
</provider>
</entry>
</component>
<component name="masterDetails">
<states>
<state key="Copyright.UI">
<settings>
<splitter-proportions>
<option name="proportions">
<list>
<option value="0.2" />
</list>
</option>
</splitter-proportions>
</settings>
</state>
</states>
</component>
</project>

12
jhboss/conf/app.conf Normal file
View File

@@ -0,0 +1,12 @@
appname = jhboss
httpport = 8080
runmode = dev
sessionon = true
[mysql]
dbhost = localhost
dbport = 3306
dbuser = root
dbpasswd =
dbbase = juhe_pay

998
jhboss/controllers/add.go Normal file
View File

@@ -0,0 +1,998 @@
/***************************************************
** @Desc : c file for ...
** @Time : 2019/8/19 18:13
** @Author : yuebin
** @File : add
** @Last Modified by : yuebin
** @Last Modified time: 2019/8/19 18:13
** @Software: GoLand
****************************************************/
package controllers
import (
"fmt"
"github.com/astaxie/beego/logs"
"github.com/astaxie/beego/validation"
"github.com/rs/xid"
"juhe/service/common"
"juhe/service/models"
"juhe/service/utils"
"strconv"
"strings"
)
type AddController struct {
BaseController
}
/*
* 添加一级菜单
*/
func (c *AddController) AddMenu() {
oneMenu := c.GetString("oneMenu")
dataJSON := new(BaseDataJSON)
menuInfo := models.MenuInfo{MenuUid: xid.New().String(), FirstMenu: oneMenu, Status: "active",
Creater: c.GetSession("userID").(string), CreateTime: utils.GetBasicDateTime()}
exist := models.FirstMenuIsExists(oneMenu)
if !exist {
menuInfo.MenuOrder = models.GetMenuLen() + 1
flag := models.InsertMenu(menuInfo)
if !flag {
dataJSON.Code = -1
dataJSON.Msg = "添加菜单失败"
} else {
dataJSON.Code = 200
}
} else {
dataJSON.Code = -1
dataJSON.Msg = "一级菜单名已经存在"
}
c.GenerateJSON(dataJSON)
}
/*
* 添加二级菜单
*/
func (c *AddController) AddSecondMenu() {
firstMenuUid := c.GetString("preMenuUid")
secondMenu := c.GetString("secondMenu")
secondRouter := c.GetString("secondRouter")
dataJSON := new(KeyDataJSON)
firstMenuInfo := models.GetMenuInfoByMenuUid(firstMenuUid)
routerExists := models.SecondRouterExists(secondRouter)
secondMenuExists := models.SecondMenuIsExists(secondMenu)
if firstMenuInfo.MenuUid == "" {
dataJSON.Code = -1
dataJSON.Key = "pre-menu-error"
dataJSON.Msg = "*一级菜单不存在"
} else if routerExists {
dataJSON.Code = -1
dataJSON.Msg = "*该路由已存在"
dataJSON.Key = "second-router-error"
} else if secondMenuExists {
dataJSON.Code = -1
dataJSON.Key = "second-menu-error"
dataJSON.Msg = "*该菜单名已经存在"
} else {
sl := models.GetSecondMenuLenByFirstMenuUid(firstMenuUid)
secondMenuInfo := models.SecondMenuInfo{MenuOrder: sl + 1, FirstMenuUid: firstMenuInfo.MenuUid,
FirstMenu: firstMenuInfo.FirstMenu, SecondMenuUid: xid.New().String(), Status: "active",
SecondMenu: secondMenu, SecondRouter: secondRouter, Creater: c.GetSession("userID").(string),
CreateTime: utils.GetBasicDateTime(), UpdateTime: utils.GetBasicDateTime(), FirstMenuOrder: firstMenuInfo.MenuOrder}
if !models.InsertSecondMenu(secondMenuInfo) {
dataJSON.Code = -1
dataJSON.Msg = "添加二级菜单失败"
} else {
dataJSON.Code = 200
dataJSON.Msg = "添加二级菜单成功"
}
}
c.GenerateJSON(dataJSON)
}
/*
* 添加权限项的处理函数
*/
func (c *AddController) AddPower() {
firstMenuUid := strings.TrimSpace(c.GetString("firstMenuUid"))
secondMenuUid := strings.TrimSpace(c.GetString("secondMenuUid"))
powerItem := strings.TrimSpace(c.GetString("powerItem"))
powerID := strings.TrimSpace(c.GetString("powerID"))
keyDataJSON := new(KeyDataJSON)
keyDataJSON.Code = -1
if powerItem == "" || len(powerItem) == 0 {
keyDataJSON.Key = ".power-name-error"
keyDataJSON.Msg = "*权限项名称不能为空"
c.GenerateJSON(keyDataJSON)
return
}
if powerID == "" || len(powerID) == 0 {
keyDataJSON.Key = ".power-id-error"
keyDataJSON.Msg = "*权限项ID不能为空"
c.GenerateJSON(keyDataJSON)
return
}
if models.PowerUidExists(powerID) {
keyDataJSON.Key = ".power-id-error"
keyDataJSON.Msg = "*权限项ID已经存在"
c.GenerateJSON(keyDataJSON)
return
}
fmt.Println(powerID)
secondMenuInfo := models.GetSecondMenuInfoBySecondMenuUid(secondMenuUid)
powerInfo := models.PowerInfo{SecondMenuUid: secondMenuUid, SecondMenu: secondMenuInfo.SecondMenu,
PowerId: powerID, PowerItem: powerItem, Creater: c.GetSession("userID").(string),
Status: "active", CreateTime: utils.GetBasicDateTime(), UpdateTime: utils.GetBasicDateTime(),
FirstMenuUid: firstMenuUid}
keyDataJSON.Code = 200
if !models.InsertPowerInfo(powerInfo) {
keyDataJSON.Key = ".power-save-success"
keyDataJSON.Msg = "添加权限项失败"
} else {
keyDataJSON.Key = ".power-save-success"
keyDataJSON.Msg = "添加权限项成功"
}
c.GenerateJSON(keyDataJSON)
}
/*
* 添加权限角色
*/
func (this *AddController) AddRole() {
roleName := strings.TrimSpace(this.GetString("roleNameAdd"))
roleRemark := strings.TrimSpace(this.GetString("roleRemark"))
keyDataJSON := new(KeyDataJSON)
if len(roleName) == 0 {
keyDataJSON.Code = -1
keyDataJSON.Key = ".role-name-error"
keyDataJSON.Msg = "*角色名称不能为空"
this.GenerateJSON(keyDataJSON)
return
}
if models.RoleNameExists(roleName) {
keyDataJSON.Code = -1
keyDataJSON.Key = ".role-name-error"
keyDataJSON.Msg = "*角色名称已经存在"
this.GenerateJSON(keyDataJSON)
return
}
roleInfo := models.RoleInfo{RoleName: roleName, RoleUid: xid.New().String(),
Creater: this.GetSession("userID").(string), Status: "active", Remark: roleRemark,
CreateTime: utils.GetBasicDateTime(), UpdateTime: utils.GetBasicDateTime()}
if !models.InsertRole(roleInfo) {
keyDataJSON.Code = -1
keyDataJSON.Key = ".role-save-success"
keyDataJSON.Msg = "添加角色失败"
this.GenerateJSON(keyDataJSON)
return
}
keyDataJSON.Code = 200
this.GenerateJSON(keyDataJSON)
}
func (this *AddController) SavePower() {
firstMenuUids := this.GetStrings("firstMenuUid[]")
secondMenuUids := this.GetStrings("secondMenuUid[]")
powerIds := this.GetStrings("powerId[]")
roleUid := strings.TrimSpace(this.GetString("roleUid"))
dataJSON := new(BaseDataJSON)
roleInfo := models.GetRoleByRoleUid(roleUid)
if len(roleUid) == 0 || len(roleInfo.RoleUid) == 0 {
dataJSON.Code = -1
this.GenerateJSON(dataJSON)
}
roleInfo.UpdateTime = utils.GetBasicDateTime()
roleInfo.ShowFirstUid = strings.Join(firstMenuUids, "||")
roleInfo.ShowSecondUid = strings.Join(secondMenuUids, "||")
roleInfo.ShowPowerUid = strings.Join(powerIds, "||")
menuInfoList := models.GetMenuInfosByMenuUids(firstMenuUids)
showFirstMenu := make([]string, 0)
for _, m := range menuInfoList {
showFirstMenu = append(showFirstMenu, m.FirstMenu)
}
roleInfo.ShowFirstMenu = strings.Join(showFirstMenu, "||")
secondMenuInfoList := models.GetSecondMenuInfoBySecondMenuUids(secondMenuUids)
showSecondMenu := make([]string, 0)
for _, m := range secondMenuInfoList {
showSecondMenu = append(showSecondMenu, m.SecondMenu)
}
roleInfo.ShowSecondMenu = strings.Join(showSecondMenu, "||")
powerList := models.GetPowerByIds(powerIds)
showPower := make([]string, 0)
for _, p := range powerList {
showPower = append(showPower, p.PowerItem)
}
roleInfo.ShowPower = strings.Join(showPower, "||")
if !models.UpdateRoleInfo(roleInfo) {
dataJSON.Code = -1
dataJSON.Msg = "更新roleInfo失败"
} else {
dataJSON.Code = 200
dataJSON.Msg = "更新roleInfo成功"
}
this.GenerateJSON(dataJSON)
}
/*
* 添加操作员
*/
func (this *AddController) AddOperator() {
loginAccount := strings.TrimSpace(this.GetString("operatorAccount"))
loginPassword := strings.TrimSpace(this.GetString("operatorPassword"))
role := strings.TrimSpace(this.GetString("operatorRole"))
status := strings.TrimSpace(this.GetString("status"))
remark := strings.TrimSpace(this.GetString("remark"))
keyDataJSON := new(KeyDataJSON)
keyDataJSON.Code = -1
if len(loginAccount) == 0 {
keyDataJSON.Key = ".operator-name-error"
keyDataJSON.Msg = "*登录账号不能为空"
} else if len(loginPassword) == 0 {
keyDataJSON.Key = ".operator-password-error"
keyDataJSON.Msg = "*初始密码不能为空"
} else if len(role) == 0 || role == "none" {
keyDataJSON.Key = ".operator-role-error"
keyDataJSON.Msg = "请选择角色"
} else if models.UserInfoExistByUserId(loginAccount) {
keyDataJSON.Key = ".operator-name-error"
keyDataJSON.Msg = "*账号已经存在"
} else {
if len(remark) == 0 {
remark = loginAccount
}
roleInfo := models.GetRoleByRoleUid(role)
userInfo := models.UserInfo{UserId: loginAccount, Passwd: utils.GetMD5Upper(loginPassword), Nick: "壮壮", Remark: remark,
Status: status, Role: role, RoleName: roleInfo.RoleName, CreateTime: utils.GetBasicDateTime(), UpdateTime: utils.GetBasicDateTime()}
if !models.InsertUser(userInfo) {
keyDataJSON.Code = 200
keyDataJSON.Msg = "添加操作员失败"
} else {
keyDataJSON.Code = 200
keyDataJSON.Msg = "添加操作员成功"
}
}
this.GenerateJSON(keyDataJSON)
}
/*
* 添加银行卡
*/
func (this *AddController) AddBankCard() {
userName := strings.TrimSpace(this.GetString("userName"))
bankCode := strings.TrimSpace(this.GetString("bankCode"))
accountName := strings.TrimSpace(this.GetString("accountName"))
certificateType := strings.TrimSpace(this.GetString("certificateType"))
phoneNo := strings.TrimSpace(this.GetString("phoneNo"))
bankName := strings.TrimSpace(this.GetString("bankName"))
bankAccountType := strings.TrimSpace(this.GetString("bankAccountType"))
bankNo := strings.TrimSpace(this.GetString("bankNo"))
identifyCard := strings.TrimSpace(this.GetString("certificateType"))
certificateNo := strings.TrimSpace(this.GetString("certificateNo"))
bankAddress := strings.TrimSpace(this.GetString("bankAddress"))
uid := strings.TrimSpace(this.GetString("uid"))
dataJSON := new(BaseDataJSON)
dataJSON.Code = -1
if len(userName) == 0 {
dataJSON.Msg = "用户名不能为空"
} else if len(bankCode) == 0 {
dataJSON.Msg = "银行编码不能为空"
} else if len(accountName) == 0 {
dataJSON.Msg = "银行开户名不能为空"
} else if len(certificateType) == 0 {
dataJSON.Msg = "证件种类不能为空"
} else if len(phoneNo) == 0 {
dataJSON.Msg = "手机号不能为空"
} else if len(bankName) == 0 {
dataJSON.Msg = "银行名称不能为空"
} else if len(bankAccountType) == 0 {
dataJSON.Msg = "银行账户类型不能为空"
} else if len(bankNo) == 0 {
dataJSON.Msg = "银行账号不能为空"
} else if len(certificateNo) == 0 {
dataJSON.Msg = "身份证号不能为空"
} else if len(bankAddress) == 0 {
dataJSON.Msg = "银行地址不能为空"
} else {
}
if dataJSON.Msg != "" {
logs.Error("添加银行卡校验失败")
} else {
if len(uid) > 0 {
bankCardInfo := models.GetBankCardByUid(uid)
bankCardInfo = models.BankCardInfo{
Id: bankCardInfo.Id, UserName: userName, BankName: bankName,
BankCode: bankCode, BankAccountType: bankAccountType,
AccountName: accountName, BankNo: bankNo, IdentifyCard: identifyCard,
CertificateNo: certificateNo, PhoneNo: phoneNo,
BankAddress: bankAddress, UpdateTime: utils.GetBasicDateTime(),
CreateTime: bankCardInfo.CreateTime, Uid: bankCardInfo.Uid,
}
if models.UpdateBankCard(bankCardInfo) {
dataJSON.Code = 200
}
} else {
bankCardInfo := models.BankCardInfo{Uid: "3333" + xid.New().String(), UserName: userName, BankName: bankName,
BankCode: bankCode, BankAccountType: bankAccountType, AccountName: accountName, BankNo: bankNo,
IdentifyCard: identifyCard, CertificateNo: certificateNo, PhoneNo: phoneNo, BankAddress: bankAddress,
UpdateTime: utils.GetBasicDateTime(), CreateTime: utils.GetBasicDateTime()}
if models.InsertBankCardInfo(bankCardInfo) {
dataJSON.Code = 200
}
}
}
this.GenerateJSON(dataJSON)
}
/*
* 添加通道
*/
func (this *AddController) AddRoad() {
roadUid := strings.TrimSpace(this.GetString("roadUid"))
roadName := strings.TrimSpace(this.GetString("roadName"))
roadRemark := strings.TrimSpace(this.GetString("roadRemark"))
productUid := strings.TrimSpace(this.GetString("productName"))
payType := strings.TrimSpace(this.GetString("payType"))
basicRate := strings.TrimSpace(this.GetString("basicRate"))
settleFee := strings.TrimSpace(this.GetString("settleFee"))
roadTotalLimit := strings.TrimSpace(this.GetString("roadTotalLimit"))
roadEverydayLimit := strings.TrimSpace(this.GetString("roadEverydayLimit"))
singleMinLimit := strings.TrimSpace(this.GetString("singleMinLimit"))
singleMaxLimit := strings.TrimSpace(this.GetString("singleMaxLimit"))
startHour := strings.TrimSpace(this.GetString("startHour"))
endHour := strings.TrimSpace(this.GetString("endHour"))
params := strings.TrimSpace(this.GetString("params"))
dataJSON := new(BaseDataJSON)
dataJSON.Code = -1
startHourTmp, err1 := strconv.Atoi(startHour)
endHourTmp, err2 := strconv.Atoi(endHour)
if err1 != nil || err2 != nil {
dataJSON.Msg = "开始时间或者结束时间设置有误"
this.GenerateJSON(dataJSON)
return
}
valid := validation.Validation{}
if v := valid.Required(roadName, "roadName"); !v.Ok {
dataJSON.Msg = "通道名称不能为空"
} else if v := valid.Required(productUid, "productUid"); !v.Ok {
dataJSON.Msg = "产品名称不能为空"
} else if v := valid.Required(payType, "payType"); !v.Ok {
dataJSON.Msg = "支付类型不能为空"
} else if v := valid.Required(basicRate, ""); !v.Ok {
dataJSON.Msg = "成本费率不能为空"
} else if v := valid.Range(startHourTmp, 0, 23, ""); !v.Ok {
dataJSON.Msg = "开始时间设置有误"
} else if v := valid.Range(endHourTmp, 0, 23, ""); !v.Ok {
dataJSON.Msg = "结束时间设置有误"
} else {
basicFee, err := strconv.ParseFloat(basicRate, 64)
if err != nil {
dataJSON.Msg = "成本汇率设置不符合规范"
}
settleFeeTmp, err := strconv.ParseFloat(settleFee, 64)
if err != nil {
dataJSON.Msg = "代付手续费设置不符合规范"
}
totalLimit, err := strconv.ParseFloat(roadTotalLimit, 64)
if err != nil {
dataJSON.Msg = "通道总额度设置不符合规范"
}
todayLimit, err := strconv.ParseFloat(roadEverydayLimit, 64)
if err != nil {
dataJSON.Msg = "每天额度设置不符合规范"
}
singleMinLimitTmp, err := strconv.ParseFloat(singleMinLimit, 64)
if err != nil {
dataJSON.Msg = "单笔最小金额设置不符合规范"
}
singleMaxLimitTmp, err := strconv.ParseFloat(singleMaxLimit, 64)
if err != nil {
dataJSON.Msg = "单笔最大金额设置不符合规范"
}
if len(dataJSON.Msg) > 0 {
this.GenerateJSON(dataJSON)
return
}
productName := ""
supplierMap := common.GetSupplierMap()
for k, v := range supplierMap {
if k == productUid {
productName = v
}
}
if len(roadUid) > 0 {
//更新通道
roadInfo := models.GetRoadInfoByRoadUid(roadUid)
roadInfo.RoadName = roadName
roadInfo.Remark = roadRemark
roadInfo.ProductUid = productUid
roadInfo.ProductName = productName
roadInfo.PayType = payType
roadInfo.BasicFee = basicFee
roadInfo.SettleFee = settleFeeTmp
roadInfo.TotalLimit = totalLimit
roadInfo.TodayLimit = todayLimit
roadInfo.SingleMaxLimit = singleMaxLimitTmp
roadInfo.SingleMinLimit = singleMinLimitTmp
roadInfo.StarHour = startHourTmp
roadInfo.EndHour = endHourTmp
roadInfo.Params = params
if models.UpdateRoadInfo(roadInfo) {
dataJSON.Code = 200
} else {
dataJSON.Msg = "通道更新失败"
}
} else {
//添加新的通道
roadUid = "4444" + xid.New().String()
roadInfo := models.RoadInfo{RoadName: roadName, RoadUid: roadUid, Remark: roadRemark,
ProductUid: productUid, ProductName: productName, PayType: payType, BasicFee: basicFee, SettleFee: settleFeeTmp,
TotalLimit: totalLimit, TodayLimit: todayLimit, SingleMinLimit: singleMinLimitTmp, Balance: common.ZERO,
SingleMaxLimit: singleMaxLimitTmp, StarHour: startHourTmp, EndHour: endHourTmp, Status: "active",
Params: params, UpdateTime: utils.GetBasicDateTime(), CreateTime: utils.GetBasicDateTime(),
}
if models.InsertRoadInfo(roadInfo) {
dataJSON.Code = 200
} else {
dataJSON.Msg = "添加新通道失败"
}
}
}
this.GenerateJSON(dataJSON)
}
func (this *AddController) AddRoadPool() {
roadPoolName := strings.TrimSpace(this.GetString("roadPoolName"))
roadPoolCode := strings.TrimSpace(this.GetString("roadPoolCode"))
keyDataJSON := new(KeyDataJSON)
keyDataJSON.Code = -1
if len(roadPoolName) == 0 {
keyDataJSON.Msg = "*通道池名称不能为空"
} else if len(roadPoolCode) == 0 {
keyDataJSON.Msg = "*通道池编号不能为空"
}
roadPoolInfo := models.RoadPoolInfo{Status: "active", RoadPoolName: roadPoolName, RoadPoolCode: roadPoolCode,
UpdateTime: utils.GetBasicDateTime(), CreateTime: utils.GetBasicDateTime()}
if models.InsertRoadPool(roadPoolInfo) {
keyDataJSON.Code = 200
keyDataJSON.Msg = "添加通道池成功"
} else {
keyDataJSON.Msg = "添加通道池失败"
}
this.GenerateJSON(keyDataJSON)
}
/*
* 添加或者更新通道池中的通道
*/
func (this *AddController) SaveRoadUid() {
roadUids := this.GetStrings("roadUid[]")
roadPoolCode := strings.TrimSpace(this.GetString("roadPoolCode"))
dataJSON := new(BaseDataJSON)
dataJSON.Code = -1
roadPoolInfo := models.GetRoadPoolByRoadPoolCode(roadPoolCode)
if roadPoolInfo.RoadPoolCode == "" {
this.GenerateJSON(dataJSON)
return
}
var uids []string
for _, uid := range roadUids {
//去掉空格
if len(uid) > 0 && models.RoadInfoExistByRoadUid(uid) {
uids = append(uids, uid)
}
}
if len(uids) > 0 {
roadUid := strings.Join(uids, "||")
roadPoolInfo.RoadUidPool = roadUid
}
roadPoolInfo.UpdateTime = utils.GetBasicDateTime()
if models.UpdateRoadPool(roadPoolInfo) {
dataJSON.Code = 200
}
this.GenerateJSON(dataJSON)
}
/*
* 添加代理信息
*/
func (this *AddController) AddAgent() {
agentName := strings.TrimSpace(this.GetString("agentName"))
agentPhone := strings.TrimSpace(this.GetString("agentPhone"))
agentLoginPassword := strings.TrimSpace(this.GetString("agentLoginPassword"))
agentVertifyPassword := strings.TrimSpace(this.GetString("agentVertifyPassword"))
agentRemark := strings.TrimSpace(this.GetString("agentRemark"))
status := strings.TrimSpace(this.GetString("status"))
agentUid := strings.TrimSpace(this.GetString("agentUid"))
keyDataJSON := new(KeyDataJSON)
keyDataJSON.Code = 200
if agentName == "" {
keyDataJSON.Code = -1
keyDataJSON.Key = "#agent-name-error"
keyDataJSON.Msg = "代理名不能为空"
} else if models.IsEixstByAgentName(agentName) {
keyDataJSON.Code = -1
keyDataJSON.Key = "#agent-name-error"
keyDataJSON.Msg = "已存在该代理名称"
} else if agentPhone == "" {
keyDataJSON.Code = -1
keyDataJSON.Key = "#agent-phone-error"
keyDataJSON.Msg = "代理注册手机号不能为空"
} else if models.IsEixstByAgentPhone(agentPhone) {
keyDataJSON.Code = -1
keyDataJSON.Key = "#agent-phone-error"
keyDataJSON.Msg = "代理商手机号已被注册"
} else if agentLoginPassword == "" {
keyDataJSON.Code = -1
keyDataJSON.Key = "#agent-login-password-error"
keyDataJSON.Msg = "密码不能为空"
} else if agentLoginPassword != agentVertifyPassword {
keyDataJSON.Code = -1
keyDataJSON.Key = "#agent-vertify-password-error"
keyDataJSON.Msg = "二次密码输入不一致"
}
if keyDataJSON.Code == -1 {
this.GenerateJSON(keyDataJSON)
return
}
if status == "" {
status = "active"
}
if agentUid == "" {
agentUid = "9999" + xid.New().String()
agentInfo := models.AgentInfo{Status: status, AgentName: agentName, AgentPhone: agentPhone,
AgentPassword: utils.GetMD5Upper(agentLoginPassword), AgentUid: agentUid, UpdateTime: utils.GetBasicDateTime(),
CreateTime: utils.GetBasicDateTime(), AgentRemark: agentRemark}
if !models.InsertAgentInfo(agentInfo) {
keyDataJSON.Code = -1
keyDataJSON.Msg = "添加代理商失败"
}
}
//创建新的账户
account := models.GetAccountByUid(agentUid)
if account.AccountUid == "" {
account.Status = "active"
account.AccountUid = agentUid
account.AccountName = agentName
account.Balance = 0.0
account.LoanAmount = 0.0
account.FreezeAmount = 0.0
account.PayforAmount = 0.0
account.SettleAmount = 0.0
account.WaitAmount = 0.0
account.UpdateTime = utils.GetBasicDateTime()
account.CreateTime = utils.GetBasicDateTime()
if models.InsetAcount(account) {
keyDataJSON.Code = 200
keyDataJSON.Msg = "插入成功"
} else {
keyDataJSON.Code = -1
keyDataJSON.Msg = "掺入失败"
}
}
this.GenerateJSON(keyDataJSON)
}
func (this *AddController) AddMerchant() {
merchantName := strings.TrimSpace(this.GetString("merchantName"))
phone := strings.TrimSpace(this.GetString("phone"))
loginPassword := strings.TrimSpace(this.GetString("loginPassword"))
verifyPassword := strings.TrimSpace(this.GetString("verifyPassword"))
merchantStatus := strings.TrimSpace(this.GetString("merchantStatus"))
remark := strings.TrimSpace(this.GetString("remark"))
keyDataJSON := new(KeyDataJSON)
keyDataJSON.Code = 200
if merchantName == "" {
keyDataJSON.Code = -1
keyDataJSON.Key = "#merchant-name-error"
keyDataJSON.Msg = "商户名称为空"
} else if models.IsExistByMerchantName(merchantName) {
keyDataJSON.Code = -1
keyDataJSON.Key = "#merchant-name-error"
keyDataJSON.Msg = "商户名已经存在"
} else if phone == "" {
keyDataJSON.Code = -1
keyDataJSON.Key = "#merchant-phone-error"
keyDataJSON.Msg = "手机号为空"
} else if models.IsExistByMerchantPhone(phone) {
keyDataJSON.Code = -1
keyDataJSON.Key = "#merchant-phone-error"
keyDataJSON.Msg = "该手机号已经注册"
} else if loginPassword == "" {
keyDataJSON.Code = -1
keyDataJSON.Key = "#merchant-login-password-error"
keyDataJSON.Msg = "登录密码为空"
} else if verifyPassword == "" {
keyDataJSON.Code = -1
keyDataJSON.Key = "#merchant-verify-password-error"
keyDataJSON.Msg = "密码确认为空"
} else if loginPassword != verifyPassword {
keyDataJSON.Key = "#merchant-verify-password-error"
keyDataJSON.Msg = "两次密码输入不正确"
} else if merchantStatus == "" {
merchantStatus = "active"
}
if keyDataJSON.Code == -1 {
this.GenerateJSON(keyDataJSON)
return
}
merchantUid := "8888" + xid.New().String()
merchantKey := "kkkk" + xid.New().String() //商户key
merchantSecret := "ssss" + xid.New().String() //商户密钥
merchantInfo := models.MerchantInfo{MerchantName: merchantName, MerchantUid: merchantUid,
LoginAccount: phone, MerchantKey: merchantKey, MerchantSecret: merchantSecret,
LoginPassword: utils.GetMD5Upper(loginPassword), Status: merchantStatus, Remark: remark,
UpdateTime: utils.GetBasicDateTime(), CreateTime: utils.GetBasicDateTime()}
if models.InsertMerchantInfo(merchantInfo) {
keyDataJSON.Code = 200
} else {
keyDataJSON.Code = -1
keyDataJSON.Msg = "插入失败"
}
//创建新的账户
account := models.GetAccountByUid(merchantUid)
if account.AccountUid == "" {
account.Status = "active"
account.AccountUid = merchantUid
account.AccountName = merchantName
account.Balance = 0.0
account.LoanAmount = 0.0
account.FreezeAmount = 0.0
account.PayforAmount = 0.0
account.SettleAmount = 0.0
account.WaitAmount = 0.0
account.UpdateTime = utils.GetBasicDateTime()
account.CreateTime = utils.GetBasicDateTime()
if models.InsetAcount(account) {
keyDataJSON.Code = 200
keyDataJSON.Msg = "插入成功"
} else {
keyDataJSON.Code = -1
keyDataJSON.Msg = "掺入失败"
}
}
this.GenerateJSON(keyDataJSON)
}
/*
* 添加商戶支付配置參數
*/
func (this *AddController) AddMerchantDeploy() {
//merchantName := strings.TrimSpace(this.GetString("merchantName"))
merchantUid := strings.TrimSpace(this.GetString("merchantNo"))
isAutoSettle := strings.TrimSpace(this.GetString("isAutoSettle"))
isAutoPayfor := strings.TrimSpace(this.GetString("isAutoPayfor"))
ipWhite := strings.TrimSpace(this.GetString("ipWhite"))
payforRoadChoose := strings.TrimSpace(this.GetString("payforRoadChoose"))
rollPayforRoadChoose := strings.TrimSpace(this.GetString("rollPayforRoadChoose"))
payforFee := strings.TrimSpace(this.GetString("payforFee"))
belongAgentName := strings.TrimSpace(this.GetString("belongAgentName"))
belongAgentUid := strings.TrimSpace(this.GetString("belongAgentUid"))
keyDataJSON := new(KeyDataJSON)
merchantInfo := models.GetMerchantByUid(merchantUid)
merchantInfo.AutoSettle = isAutoSettle
merchantInfo.AutoPayFor = isAutoPayfor
merchantInfo.WhiteIps = ipWhite
merchantInfo.BelongAgentName = belongAgentName
merchantInfo.BelongAgentUid = belongAgentUid
if payforRoadChoose != "" {
roadInfo := models.GetRoadInfoByName(payforRoadChoose)
merchantInfo.SinglePayForRoadName = payforRoadChoose
merchantInfo.SinglePayForRoadUid = roadInfo.RoadUid
}
if rollPayforRoadChoose != "" {
rollPoolInfo := models.GetRoadPoolByName(rollPayforRoadChoose)
merchantInfo.RollPayForRoadName = rollPayforRoadChoose
merchantInfo.RollPayForRoadCode = rollPoolInfo.RoadPoolCode
}
tmp, err := strconv.ParseFloat(payforFee, 64)
if err != nil {
logs.Error("手续费由字符串转为float64失败")
tmp = common.PAYFOR_FEE
}
merchantInfo.PayforFee = tmp
if models.UpdateMerchant(merchantInfo) {
keyDataJSON.Code = 200
} else {
keyDataJSON.Code = -1
}
this.GenerateJSON(keyDataJSON)
}
func (this *AddController) AddMerchantPayType() {
merchantNo := strings.TrimSpace(this.GetString("merchantNo"))
payType := strings.TrimSpace(this.GetString("payType"))
singleRoad := strings.TrimSpace(this.GetString("singleRoad"))
singleRoadPlatformFee := strings.TrimSpace(this.GetString("singleRoadPlatformFee"))
singleRoadAgentFee := strings.TrimSpace(this.GetString("singleRoadAgentFee"))
rollPoolRoad := strings.TrimSpace(this.GetString("rollPoolRoad"))
rollRoadPlatformFee := strings.TrimSpace(this.GetString("rollRoadPlatformFee"))
rollRoadAgentFee := strings.TrimSpace(this.GetString("rollRoadAgentFee"))
isLoan := strings.TrimSpace(this.GetString("isLoan"))
loanRate := strings.TrimSpace(this.GetString("loanRate"))
loanDays := strings.TrimSpace(this.GetString("loanDays"))
unfreezeTimeHour := strings.TrimSpace(this.GetString("unfreezeTimeHour"))
keyDataJSON := new(KeyDataJSON)
if payType == "" || payType == "none" {
keyDataJSON.Code = -1
keyDataJSON.Msg = "操作失败,请选择支付类型"
this.GenerateJSON(keyDataJSON)
return
}
if singleRoad == "" && (singleRoadPlatformFee != "" || singleRoadAgentFee != "") {
keyDataJSON.Code = -1
keyDataJSON.Msg = "单通道选项不能为空"
} else if rollPoolRoad == "" && (rollRoadPlatformFee != "" || rollRoadAgentFee != "") {
keyDataJSON.Code = -1
keyDataJSON.Msg = "轮询通道选项不能为空"
}
if keyDataJSON.Code == -1 {
this.GenerateJSON(keyDataJSON)
return
}
//将字符串转变为float64或者int类型
a, err := strconv.ParseFloat(singleRoadPlatformFee, 64)
if err != nil {
a = 0.0
}
b, err := strconv.ParseFloat(singleRoadAgentFee, 64)
if err != nil {
b = 0.0
}
c, err := strconv.ParseFloat(rollRoadPlatformFee, 64)
if err != nil {
c = 0.0
}
d, err := strconv.ParseFloat(rollRoadAgentFee, 64)
if err != nil {
d = 0.0
}
e, err := strconv.ParseFloat(loanRate, 64)
if err != nil {
e = 0.0
}
i, err := strconv.Atoi(loanDays)
if err != nil {
i = 0
}
j, err := strconv.Atoi(unfreezeTimeHour)
if err != nil {
j = 0
}
var merchantDeployInfo models.MerchantDeployInfo
merchantDeployInfo.MerchantUid = merchantNo
merchantDeployInfo.PayType = payType
merchantDeployInfo.SingleRoadName = singleRoad
merchantDeployInfo.SingleRoadPlatformRate = a
merchantDeployInfo.SingleRoadAgentRate = b
merchantDeployInfo.RollRoadPlatformRate = c
merchantDeployInfo.RollRoadAgentRate = d
merchantDeployInfo.IsLoan = isLoan
merchantDeployInfo.LoanRate = e
merchantDeployInfo.LoanDays = i
merchantDeployInfo.UnfreezeHour = j
merchantDeployInfo.RollRoadName = rollPoolRoad
roadInfo := models.GetRoadInfoByName(singleRoad)
rollPoolInfo := models.GetRoadPoolByName(rollPoolRoad)
merchantDeployInfo.SingleRoadUid = roadInfo.RoadUid
merchantDeployInfo.RollRoadCode = rollPoolInfo.RoadPoolCode
//如果该用户的改支付类型已经存在,那么进行更新,否则进行添加
if models.IsExistByUidAndPayType(merchantNo, payType) {
if singleRoad == "" && rollPoolRoad == "" {
//表示需要删除该支付类型的通道
if models.DeleteMerchantDeployByUidAndPayType(merchantNo, payType) {
keyDataJSON.Code = 200
keyDataJSON.Msg = "删除该支付类型通道成功"
} else {
keyDataJSON.Code = -1
keyDataJSON.Msg = "删除该支付类型通道失败"
}
} else {
tmpInfo := models.GetMerchantDeployByUidAndPayType(merchantNo, payType)
merchantDeployInfo.Id = tmpInfo.Id
merchantDeployInfo.Status = tmpInfo.Status
merchantDeployInfo.UpdateTime = utils.GetBasicDateTime()
if models.UpdateMerchantDeploy(merchantDeployInfo) {
keyDataJSON.Code = 200
keyDataJSON.Msg = "更新成功"
} else {
keyDataJSON.Code = -1
keyDataJSON.Msg = "更新失败"
}
}
} else {
if singleRoad == "" && rollPoolRoad == "" {
keyDataJSON.Code = -1
keyDataJSON.Msg = "参数不能为空"
} else {
merchantDeployInfo.CreateTime = utils.GetBasicDateTime()
merchantDeployInfo.UpdateTime = utils.GetBasicDateTime()
merchantDeployInfo.Status = common.ACTIVE
if models.InsertMerchantDeployInfo(merchantDeployInfo) {
keyDataJSON.Code = 200
keyDataJSON.Msg = "添加支付类型成功"
} else {
keyDataJSON.Code = -1
keyDataJSON.Msg = "添加支付类型失败"
}
}
}
this.GenerateJSON(keyDataJSON)
}
/*
*后台提交的下发记录
*/
func (c *AddController) AddPayFor() {
merchantUid := strings.TrimSpace(c.GetString("merchantUid"))
merchantName := strings.TrimSpace(c.GetString("merchantName"))
bankName := strings.TrimSpace(c.GetString("bankName"))
accountName := strings.TrimSpace(c.GetString("accountName"))
bankUid := strings.TrimSpace(c.GetString("bankUid"))
bankNo := strings.TrimSpace(c.GetString("bankNo"))
//cardType := strings.TrimSpace(c.GetString("cardType"))
bankAddress := strings.TrimSpace(c.GetString("bankAddress"))
phone := strings.TrimSpace(c.GetString("phone"))
payForAmount := strings.TrimSpace(c.GetString("payForAmount"))
keyDataJSON := new(KeyDataJSON)
keyDataJSON.Code = -1
if merchantUid == "" {
keyDataJSON.Msg = "请选择需要下发的商户"
c.GenerateJSON(keyDataJSON)
return
}
if bankUid == "" {
keyDataJSON.Msg = "请选择发下银行卡"
c.GenerateJSON(keyDataJSON)
return
}
money, err := strconv.ParseFloat(payForAmount, 64)
if err != nil {
logs.Error("add pay for fail ", err)
keyDataJSON.Msg = "下发金额输入不正确"
c.GenerateJSON(keyDataJSON)
return
}
accountInfo := models.GetAccountByUid(merchantUid)
if accountInfo.SettleAmount < money+common.PAYFOR_FEE {
keyDataJSON.Msg = "用户可用金额不够"
c.GenerateJSON(keyDataJSON)
return
}
bankInfo := models.GetBankCardByUid(bankUid)
if bankInfo.BankNo != bankNo || bankInfo.AccountName != accountName || bankInfo.PhoneNo != phone {
keyDataJSON.Msg = "银行卡信息有误,请连接管理员"
c.GenerateJSON(keyDataJSON)
return
}
payFor := models.PayforInfo{PayforUid: "pppp" + xid.New().String(), MerchantUid: merchantUid, MerchantName: merchantName, PhoneNo: phone,
MerchantOrderId: xid.New().String(), BankOrderId: "4444" + xid.New().String(), PayforFee: common.PAYFOR_FEE, Type: common.SELF_MERCHANT,
PayforAmount: money, PayforTotalAmount: money + common.PAYFOR_FEE, BankCode: bankInfo.BankCode, BankName: bankName, IsSend: common.NO,
BankAccountName: bankInfo.AccountName, BankAccountNo: bankInfo.BankNo, BankAccountType: bankInfo.BankAccountType, BankAccountAddress: bankAddress,
Status: common.PAYFOR_COMFRIM, CreateTime: utils.GetBasicDateTime(), UpdateTime: utils.GetBasicDateTime()}
if models.InsertPayfor(payFor) {
keyDataJSON.Code = 200
} else {
keyDataJSON.Code = -1
keyDataJSON.Msg = "代付下发提交失败"
}
c.GenerateJSON(keyDataJSON)
}
func (c *AddController) AddSelfPayFor() {
bankUid := strings.TrimSpace(c.GetString("bankUid"))
bankName := strings.TrimSpace(c.GetString("bankName"))
accountName := strings.TrimSpace(c.GetString("accountName"))
bankNo := strings.TrimSpace(c.GetString("bankNo"))
//cardType := strings.TrimSpace(c.GetString("cardType"))
bankAddress := strings.TrimSpace(c.GetString("bankAddress"))
phone := strings.TrimSpace(c.GetString("phone"))
payForAmount := strings.TrimSpace(c.GetString("payForAmount"))
keyDataJSON := new(KeyDataJSON)
keyDataJSON.Code = -1
if bankUid == "" {
keyDataJSON.Msg = "银行卡uid不能为空请联系技术人员"
c.GenerateJSON(keyDataJSON)
return
}
money, err := strconv.ParseFloat(payForAmount, 64)
if err != nil {
logs.Error("self payfor money fail: ", err)
keyDataJSON.Msg = "输入金额有误,请仔细检查"
c.GenerateJSON(keyDataJSON)
return
}
bankInfo := models.GetBankCardByUid(bankUid)
//需要对前端传入的数据做校验,不能完全相信前端的数据
if bankInfo.AccountName != accountName || bankInfo.BankNo != bankNo || bankInfo.PhoneNo != phone {
keyDataJSON.Msg = "前端页面数据有篡改,请注意资金安全"
c.GenerateJSON(keyDataJSON)
return
}
selfPayFor := models.PayforInfo{PayforUid: "pppp" + xid.New().String(), BankOrderId: "4444" + xid.New().String(), PayforFee: common.ZERO, Type: common.SELF_HELP,
PayforAmount: money, PayforTotalAmount: money + common.ZERO, BankCode: bankInfo.BankCode, BankName: bankName, IsSend: common.NO,
BankAccountName: bankInfo.AccountName, BankAccountNo: bankInfo.BankNo, BankAccountType: bankInfo.BankAccountType, BankAccountAddress: bankAddress,
Status: common.PAYFOR_COMFRIM, CreateTime: utils.GetBasicDateTime(), UpdateTime: utils.GetBasicDateTime()}
if models.InsertPayfor(selfPayFor) {
keyDataJSON.Code = 200
} else {
keyDataJSON.Msg = "数据处理失败,请重新提交"
}
c.GenerateJSON(keyDataJSON)
}

View File

@@ -0,0 +1,36 @@
/***************************************************
** @Desc : c file for ...
** @Time : 2019/8/13 18:09
** @Author : yuebin
** @File : base_controller
** @Last Modified by : yuebin
** @Last Modified time: 2019/8/13 18:09
** @Software: GoLand
****************************************************/
package controllers
import "github.com/astaxie/beego"
type BaseController struct {
beego.Controller
}
func (c *BaseController) GenerateJSON(dataJSON interface{}) {
c.Data["json"] = dataJSON
c.ServeJSON()
}
func (c *BaseController) Prepare() {
userID, ok := c.GetSession("userID").(string)
if !ok || userID == "" {
//用户没有登录,或者登录到期了,则跳转登录主页面
dataJSON := new(BaseDataJSON)
dataJSON.Code = 404
dataJSON.Msg = "登录已经过期!"
c.Data["json"] = dataJSON
c.ServeJSON()
} else {
//重新赋值给session
c.SetSession("userID", userID)
}
}

235
jhboss/controllers/datas.go Normal file
View File

@@ -0,0 +1,235 @@
/***************************************************
** @Desc : c file for ...
** @Time : 2019/8/16 10:03
** @Author : yuebin
** @File : datas
** @Last Modified by : yuebin
** @Last Modified time: 2019/8/16 10:03
** @Software: GoLand
****************************************************/
package controllers
import (
"juhe/service/models"
)
type BaseDataJSON struct {
Msg string
Code int
}
type KeyDataJSON struct {
Msg string
Code int
Key string
}
type MenuDataJSON struct {
StartIndex int
DisplayCount int
CurrentPage int
TotalPage int
Code int
Msg string
MenuList []models.MenuInfo
}
type SecondMenuDataJSON struct {
StartIndex int
DisplayCount int
CurrentPage int
TotalPage int
Code int
Msg string
SecondMenuList []models.SecondMenuInfo
}
type PowerItemDataJSON struct {
StartIndex int
DisplayCount int
CurrentPage int
TotalPage int
Code int
Msg string
PowerItemList []models.PowerInfo
}
type RoleInfoDataJSON struct {
StartIndex int
DisplayCount int
CurrentPage int
TotalPage int
Code int
Msg string
RoleInfoList []models.RoleInfo
}
type DeployTreeJSON struct {
Msg string
Code int
Key string
AllFirstMenu []models.MenuInfo
ShowFirstMenuUid map[string]bool
AllSecondMenu []models.SecondMenuInfo
ShowSecondMenuUid map[string]bool
AllPower []models.PowerInfo
ShowPowerUid map[string]bool
}
type OperatorDataJSON struct {
Msg string
Code int
StartIndex int
DisplayCount int
CurrentPage int
TotalPage int
OperatorList []models.UserInfo
}
type EditOperatorDataJSON struct {
Code int
Msg string
OperatorList []models.UserInfo
RoleList []models.RoleInfo
}
type BankCardDataJSON struct {
Msg string
Code int
StartIndex int
DisplayCount int
CurrentPage int
TotalPage int
BankCardInfoList []models.BankCardInfo
}
type RoadDataJSON struct {
Msg string
Code int
StartIndex int
DisplayCount int
CurrentPage int
TotalPage int
RoadInfoList []models.RoadInfo
RoadPool models.RoadPoolInfo
}
type RoadPoolDataJSON struct {
Msg string
Code int
StartIndex int
DisplayCount int
CurrentPage int
TotalPage int
RoadPoolInfoList []models.RoadPoolInfo
}
type MerchantDataJSON struct {
Msg string
Code int
StartIndex int
DisplayCount int
CurrentPage int
TotalPage int
MerchantList []models.MerchantInfo
}
type MerchantDeployDataJSON struct {
Code int
Msg string
MerchantDeploy models.MerchantDeployInfo
}
type AccountDataJSON struct {
Msg string
Code int
StartIndex int
DisplayCount int
CurrentPage int
TotalPage int
AccountList []models.AccountInfo
}
type AccountHistoryDataJSON struct {
Msg string
Code int
StartIndex int
DisplayCount int
CurrentPage int
TotalPage int
AccountHistoryList []models.AccountHistoryInfo
}
type AgentDataJSON struct {
Msg string
Code int
StartIndex int
DisplayCount int
CurrentPage int
TotalPage int
AgentList []models.AgentInfo
}
type ProductDataJSON struct {
Msg string
Code int
ProductMap map[string]string
}
type OrderDataJSON struct {
Msg string
Code int
StartIndex int
DisplayCount int
CurrentPage int
TotalPage int
OrderList []models.OrderInfo
AllAmount float64
SuccessRate string
NotifyUrl string
}
type ListDataJSON struct {
Msg string
Code int
StartIndex int
DisplayCount int
CurrentPage int
TotalPage int
List []models.OrderProfitInfo
AllAmount float64
SupplierProfit float64
AgentProfit float64
PlatformProfit float64
}
type PayForDataJSON struct {
Msg string
Code int
StartIndex int
DisplayCount int
CurrentPage int
TotalPage int
PayForList []models.PayforInfo
}
type BalanceDataJSON struct {
Msg string
Code int
Balance float64
}
type NotifyBankOrderIdListJSON struct {
Msg string
Code int
NotifyIdList []string
}
type ProfitListJSON struct {
TotalAmount float64
PlatformTotalProfit float64
AgentTotalProfit float64
Msg string
Code int
ProfitList []models.PlatformProfit
}

View File

@@ -0,0 +1,340 @@
/***************************************************
** @Desc : c file for ...
** @Time : 2019/8/21 16:51
** @Author : yuebin
** @File : delete
** @Last Modified by : yuebin
** @Last Modified time: 2019/8/21 16:51
** @Software: GoLand
****************************************************/
package controllers
import (
"github.com/astaxie/beego/logs"
"juhe/service/models"
"juhe/service/utils"
"sort"
"strings"
)
type Deletecontroller struct {
BaseController
}
func (c *Deletecontroller) Finish() {
remainderFirstMenuUid := make([]string, 0)
remainderFirstMenu := make([]string, 0)
remainderSecondMenuUid := make([]string, 0)
remainderSecondMenu := make([]string, 0)
remainderPowerId := make([]string, 0)
remainderPower := make([]string, 0)
allRoleInfo := models.GetRole()
//如果有删除任何的东西,需要重新赋值权限
for _, r := range allRoleInfo {
for _, showFirstUid := range strings.Split(r.ShowFirstUid, "||") {
if models.FirstMenuUidIsExists(showFirstUid) {
remainderFirstMenuUid = append(remainderFirstMenuUid, showFirstUid)
menuInfo := models.GetMenuInfoByMenuUid(showFirstUid)
remainderFirstMenu = append(remainderFirstMenu, menuInfo.FirstMenu)
}
}
for _, showSecondUid := range strings.Split(r.ShowSecondUid, "||") {
if models.SecondMenuUidIsExists(showSecondUid) {
remainderSecondMenuUid = append(remainderSecondMenuUid, showSecondUid)
secondMenuInfo := models.GetSecondMenuInfoBySecondMenuUid(showSecondUid)
remainderSecondMenu = append(remainderSecondMenu, secondMenuInfo.SecondMenu)
}
}
for _, showPowerId := range strings.Split(r.ShowPowerUid, "||") {
if models.PowerUidExists(showPowerId) {
remainderPowerId = append(remainderPowerId, showPowerId)
powerInfo := models.GetPowerById(showPowerId)
remainderPower = append(remainderPower, powerInfo.PowerItem)
}
}
r.ShowFirstUid = strings.Join(remainderFirstMenuUid, "||")
r.ShowFirstMenu = strings.Join(remainderFirstMenu, "||")
r.ShowSecondUid = strings.Join(remainderSecondMenuUid, "||")
r.ShowSecondMenu = strings.Join(remainderSecondMenu, "||")
r.ShowPowerUid = strings.Join(remainderPowerId, "||")
r.ShowPower = strings.Join(remainderPower, "||")
r.UpdateTime = utils.GetBasicDateTime()
models.UpdateRoleInfo(r)
}
}
func (c *Deletecontroller) DeleteMenu() {
menuUid := c.GetString("menuUid")
menuInfo := models.GetMenuInfoByMenuUid(menuUid)
dataJSON := new(BaseDataJSON)
if menuInfo.MenuUid == "" {
dataJSON.Msg = "不存在该菜单"
dataJSON.Code = -1
} else {
logs.Info(c.GetSession("userID").(string) + ",执行了删除一级菜单操作")
models.DeleteMenuInfo(menuUid)
//删除该一级目下下的所有二级目录
models.DeleteSecondMenuByFirstMenuUid(menuUid)
SortFirstMenuOrder()
dataJSON.Code = 200
}
c.Data["json"] = dataJSON
c.ServeJSONP()
}
/*
* 对一级菜单重新进行排序
*/
func SortFirstMenuOrder() {
menuInfoList := models.GetMenuAll()
sort.Sort(models.MenuInfoSlice(menuInfoList))
for i := 0; i < len(menuInfoList); i++ {
m := menuInfoList[i]
m.UpdateTime = utils.GetBasicDateTime()
m.MenuOrder = i + 1
models.UpdateMenuInfo(m)
//对应的二级菜单也应该重新分配顺序号
SortSecondMenuOrder(m)
}
}
/*
* 对二级菜单分配顺序号
*/
func SortSecondMenuOrder(firstMenuInfo models.MenuInfo) {
secondMenuInfoList := models.GetSecondMenuListByFirstMenuUid(firstMenuInfo.MenuUid)
for _, sm := range secondMenuInfoList {
sm.FirstMenuOrder = firstMenuInfo.MenuOrder
sm.UpdateTime = utils.GetBasicDateTime()
models.UpdateSecondMenu(sm)
//删除下下一级的所有权限项
models.DeletePowerBySecondUid(sm.SecondMenuUid)
}
}
func (c *Deletecontroller) DeleteSecondMenu() {
secondMenuUid := strings.TrimSpace(c.GetString("secondMenuUid"))
secondMenuInfo := models.GetSecondMenuInfoBySecondMenuUid(secondMenuUid)
dataJSON := new(BaseDataJSON)
if secondMenuUid == "" || secondMenuInfo.SecondMenuUid == "" {
dataJSON.Code = -1
dataJSON.Msg = "该二级菜单不存在"
} else {
if models.DeleteSecondMenuBySecondMenuUid(secondMenuUid) {
dataJSON.Code = 200
ml := models.GetSecondMenuLenByFirstMenuUid(secondMenuInfo.FirstMenuUid)
//删除该二级页面下的所有权限项
models.DeletePowerBySecondUid(secondMenuUid)
if ml == 0 {
//如果该二级类目已经被全部删除,那么对应的一级类目也应当删除
models.DeleteMenuInfo(secondMenuInfo.FirstMenuUid)
SortFirstMenuOrder()
} else {
secondMenuInfoList := models.GetSecondMenuListByFirstMenuUid(secondMenuInfo.FirstMenuUid)
sort.Sort(models.SecondMenuSlice(secondMenuInfoList))
for i := 0; i < len(secondMenuInfoList); i++ {
m := secondMenuInfoList[i]
models.UpdateSecondMenuOrderBySecondUid(m.SecondMenuUid, i+1)
}
}
} else {
dataJSON.Code = -1
dataJSON.Msg = "删除失败"
}
}
c.Data["json"] = dataJSON
c.ServeJSON()
}
/*
* 删除权限项
*/
func (c *Deletecontroller) DeletePowerItem() {
powerID := strings.TrimSpace(c.GetString("powerID"))
models.DeletePowerItemByPowerID(powerID)
dataJSON := new(BaseDataJSON)
dataJSON.Code = 200
c.GenerateJSON(dataJSON)
}
/*
* 删除角色
*/
func (c *Deletecontroller) DeleteRole() {
roleUid := strings.TrimSpace(c.GetString("roleUid"))
dataJSON := new(BaseDataJSON)
if models.DeleteRoleByRoleUid(roleUid) {
dataJSON.Code = 200
} else {
dataJSON.Code = -1
}
c.GenerateJSON(dataJSON)
}
/*
* 删除操作员
*/
func (c *Deletecontroller) DeleteOperator() {
userId := strings.TrimSpace(c.GetString("userId"))
dataJSON := new(BaseDataJSON)
if models.DeleteUserByUserId(userId) {
dataJSON.Code = 200
} else {
dataJSON.Code = -1
}
c.GenerateJSON(dataJSON)
}
func (c *Deletecontroller) DeleteBankCardRecord() {
uid := strings.TrimSpace(c.GetString("uid"))
dataJSON := new(BankCardDataJSON)
dataJSON.Code = -1
if models.DeleteBankCardByUid(uid) {
dataJSON.Code = 200
}
c.GenerateJSON(dataJSON)
}
/*
* 删除通道操作
*/
func (c *Deletecontroller) DeleteRoad() {
roadUid := strings.TrimSpace(c.GetString("roadUid"))
dataJSON := new(BaseDataJSON)
dataJSON.Code = -1
if models.DeleteRoadByRoadUid(roadUid) {
dataJSON.Code = 200
}
params := make(map[string]string)
roadPoolInfoList := models.GetAllRollPool(params)
//将轮询池中的对应的通道删除
for _, roadPoolInfo := range roadPoolInfoList {
var uids []string
roadInfoList := strings.Split(roadPoolInfo.RoadUidPool, "||")
for _, uid := range roadInfoList {
if uid != roadUid {
uids = append(uids, uid)
}
}
roadPoolInfo.RoadUidPool = strings.Join(uids, "||")
roadPoolInfo.UpdateTime = utils.GetBasicDateTime()
models.UpdateRoadPool(roadPoolInfo)
}
c.GenerateJSON(dataJSON)
}
/*
* 删除通道池
*/
func (c *Deletecontroller) DeleteRoadPool() {
roadPoolCode := strings.TrimSpace(c.GetString("roadPoolCode"))
dataJSON := new(BaseDataJSON)
dataJSON.Code = -1
if models.DeleteRoadPoolByCode(roadPoolCode) {
dataJSON.Code = 200
} else {
dataJSON.Msg = "删除通道池失败"
}
c.GenerateJSON(dataJSON)
}
/*
* 删除商户
*/
func (c *Deletecontroller) DeleteMerchant() {
merchantUid := strings.TrimSpace(c.GetString("merchantUid"))
keyDataJSON := new(KeyDataJSON)
if merchantUid == "" {
keyDataJSON.Code = -1
c.GenerateJSON(keyDataJSON)
return
}
if models.DeleteMerchantByUid(merchantUid) {
keyDataJSON.Code = 200
} else {
keyDataJSON.Code = -1
}
c.GenerateJSON(keyDataJSON)
}
/*
* 删除账户
*/
func (c *Deletecontroller) DeleteAccount() {
accountUid := strings.TrimSpace(c.GetString("accountUid"))
dataJSON := new(BaseDataJSON)
models.IsExistByMerchantUid(accountUid)
if models.IsExistByMerchantUid(accountUid) || models.IsExistByAgentUid(accountUid) {
dataJSON.Code = -1
dataJSON.Msg = "用户还存在,不能删除"
} else {
if models.DeleteAccountByUid(accountUid) {
dataJSON.Code = 200
dataJSON.Msg = "删除账户成功"
} else {
dataJSON.Code = -1
dataJSON.Msg = "删除账户失败"
}
}
c.GenerateJSON(dataJSON)
}
func (c *Deletecontroller) DeleteAgent() {
agentUid := strings.TrimSpace(c.GetString("agentUid"))
keyDataJSON := new(KeyDataJSON)
//判断是否有商户还绑定了该代理
if models.IsExistMerchantByAgentUid(agentUid) {
keyDataJSON.Code = -1
keyDataJSON.Msg = "已有商户绑定改代理,不能删除"
} else {
if models.DeleteAgentByAgentUid(agentUid) {
keyDataJSON.Code = 200
} else {
keyDataJSON.Code = -1
keyDataJSON.Msg = "删除失败"
}
}
c.GenerateJSON(keyDataJSON)
}
func (c *Deletecontroller) DeleteAgentRelation() {
merchantUid := strings.TrimSpace(c.GetString("merchantUid"))
merchantInfo := models.GetMerchantByUid(merchantUid)
keyDataJSON := new(KeyDataJSON)
keyDataJSON.Code = 200
if merchantInfo.MerchantUid == "" {
keyDataJSON.Code = -1
keyDataJSON.Msg = "不存在这样的商户"
} else {
merchantInfo.UpdateTime = utils.GetBasicDateTime()
merchantInfo.BelongAgentUid = ""
merchantInfo.BelongAgentName = ""
if !models.UpdateMerchant(merchantInfo) {
keyDataJSON.Code = -1
keyDataJSON.Msg = "更新商户失败"
}
}
c.GenerateJSON(merchantInfo)
}

View File

@@ -0,0 +1,56 @@
/***************************************************
** @Desc : 过滤功能
** @Time : 2019/8/8 16:10
** @Author : yuebin
** @File : filter
** @Last Modified by : yuebin
** @Last Modified time: 2019/8/8 16:10
** @Software: GoLand
****************************************************/
package controllers
import (
"fmt"
"github.com/astaxie/beego"
"github.com/astaxie/beego/context"
"strings"
)
type FilterController struct {
beego.Controller
}
var FilterLogin = func(ctx *context.Context) {
userID, ok := ctx.Input.Session("userID").(string)
if !ok || userID == "" {
if !strings.Contains(ctx.Request.RequestURI, "/login.html") &&
!strings.Contains(ctx.Request.RequestURI, "/getVerifyImg") &&
!strings.Contains(ctx.Request.RequestURI, "/favicon.ico") &&
!ctx.Input.IsAjax() {
ctx.Redirect(302, "/login.html")
}
} else {
if strings.Contains(ctx.Request.RequestURI, "/login.html") {
ctx.Redirect(302, "/")
}
}
}
//jsonp请求过来的函数
func (c *FilterController) Filter() {
userID, ok := c.GetSession("userID").(string)
dataJSON := new(struct {
Code int
})
if !ok || userID == "" {
dataJSON.Code = 404
} else {
dataJSON.Code = 200
c.SetSession("userID", userID)
}
fmt.Println(dataJSON)
c.Data["json"] = dataJSON
c.ServeJSON()
}

1006
jhboss/controllers/get.go Normal file

File diff suppressed because it is too large Load Diff

106
jhboss/controllers/login.go Normal file
View File

@@ -0,0 +1,106 @@
package controllers
import (
"github.com/astaxie/beego"
"github.com/astaxie/beego/logs"
"github.com/astaxie/beego/validation"
"juhe/service/common"
"juhe/service/models"
"juhe/service/utils"
)
type LoginController struct {
beego.Controller
}
func (c *LoginController) Prepare() {
}
func (c *LoginController) Login() {
userID := c.GetString("userID")
passWD := c.GetString("passwd")
code := c.GetString("Code")
dataJSON := new(KeyDataJSON)
valid := validation.Validation{}
if v := valid.Required(userID, "userID"); !v.Ok {
dataJSON.Key = v.Error.Key
dataJSON.Msg = "手机号不能为空!"
} else if v := valid.Required(passWD, "passWD"); !v.Ok {
dataJSON.Key = v.Error.Key
dataJSON.Msg = "登录密码不能为空!"
} else if v := valid.Length(code, common.VERIFY_CODE_LEN, "code"); !v.Ok {
dataJSON.Key = v.Error.Key
dataJSON.Msg = "验证码不正确!"
}
userInfo := models.GetUserInfoByUserID(userID)
if userInfo.UserId == "" {
dataJSON.Key = "userID"
dataJSON.Msg = "用户不存在,请求联系管理员!"
} else {
codeInterface := c.GetSession("verifyCode")
if userInfo.Passwd != utils.GetMD5Upper(passWD) {
dataJSON.Key = "passWD"
dataJSON.Msg = "密码不正确!"
} else if codeInterface == nil {
dataJSON.Key = "code"
dataJSON.Msg = "验证码失效!"
} else if code != codeInterface.(string) {
dataJSON.Key = "code"
dataJSON.Msg = "验证码不正确!"
} else if userInfo.Status == "unactive" {
dataJSON.Key = "unactive"
dataJSON.Msg = "用户已被冻结!"
} else if userInfo.Status == "del" {
dataJSON.Key = "del"
dataJSON.Msg = "用户已被删除!"
}
}
go func() {
userInfo.Ip = c.Ctx.Input.IP()
models.UpdateUserInfoIP(userInfo)
}()
if dataJSON.Key == "" {
c.SetSession("userID", userID)
c.DelSession("verifyCode")
}
c.Data["json"] = dataJSON
c.ServeJSON()
}
/*
* 退出登录,删除session中的数据避免数据量过大内存吃紧
*/
func (c *LoginController) Logout() {
dataJSON := new(BaseDataJSON)
c.DelSession("userID")
dataJSON.Code = 200
c.Data["json"] = dataJSON
c.ServeJSON()
}
/*
* 验证码获取如果获取成功并将验证码存到session中
*/
func (c *LoginController) GetVerifyImg() {
Image, verifyCode := utils.GenerateVerifyCodeImg()
if Image == nil || len(verifyCode) != common.VERIFY_CODE_LEN {
logs.Error("获取验证码图片失败!")
} else {
c.SetSession("verifyCode", verifyCode)
}
logs.Info("验证码:", verifyCode)
Image.WriteTo(c.Ctx.ResponseWriter)
}

View File

@@ -0,0 +1,132 @@
/***************************************************
** @Desc : c file for ...
** @Time : 2019/10/23 15:20
** @Author : yuebin
** @File : page_controller
** @Last Modified by : yuebin
** @Last Modified time: 2019/10/23 15:20
** @Software: GoLand
****************************************************/
package controllers
import "github.com/astaxie/beego"
type PageController struct {
beego.Controller
}
func (c *PageController) Index() {
c.TplName = "index.html"
}
func (c *PageController) LoginPage() {
c.TplName = "login.html"
}
func (c *PageController) AccountPage() {
c.TplName = "account.html"
}
func (c *PageController) AccountHistoryPage() {
c.TplName = "account_history.html"
}
func (c *PageController) BankCardPage() {
c.TplName = "bank_card.html"
}
func (c *PageController) CreateAgentPage() {
c.TplName = "create_agent.html"
}
func (c *PageController) EditRolePage() {
c.TplName = "edit_role.html"
}
func (c *PageController) FirstMenuPage() {
c.TplName = "first_menu.html"
}
func (c *PageController) MainPage() {
c.TplName = "main.html"
}
func (c *PageController) MenuPage() {
c.TplName = "menu.html"
}
func (c *PageController) MerchantPage() {
c.TplName = "merchant.html"
}
func (c *PageController) OperatorPage() {
c.TplName = "operator.html"
}
func (c *PageController) PowerPage() {
c.TplName = "power.html"
}
func (c *PageController) RoadPage() {
c.TplName = "road.html"
}
func (c *PageController) RoadPoolPage() {
c.TplName = "road_pool.html"
}
func (c *PageController) RoadProfitPage() {
c.TplName = "road_profit.html"
}
func (c *PageController) RolePage() {
c.TplName = "role.html"
}
func (c *PageController) SecondMenuPage() {
c.TplName = "second_menu.html"
}
func (c *PageController) OrderInfoPage() {
c.TplName = "order_info.html"
}
func (c *PageController) OrderProfitPage() {
c.TplName = "order_profit.html"
}
func (c *PageController) MerchantPayforPage() {
c.TplName = "merchant_payfor.html"
}
func (c *PageController) SelfPayforPage() {
c.TplName = "self_payfor.html"
}
func (c *PageController) PayforRecordPage() {
c.TplName = "payfor_record.html"
}
func (c *PageController) ConfirmPage() {
c.TplName = "confirm.html"
}
func (c *PageController) SelfNotifyPage() {
c.TplName = "self_notify.html"
}
func (c *PageController) SelfPlusSubPage() {
c.TplName = "self_plus_sub.html"
}
func (c *PageController) AgentToMerchantPage() {
c.TplName = "agent_to_merchant.html"
}
func (c *PageController) PlatFormProfitPage() {
c.TplName = "platform_profit.html"
}
func (c *PageController) AgentProfitPage() {
c.TplName = "agent_profit.html"
}

102
jhboss/controllers/query.go Normal file
View File

@@ -0,0 +1,102 @@
/***************************************************
** @Desc : This file for ...
** @Time : 2019/11/6 14:03
** @Author : yuebin
** @File : query.go
** @Last Modified by : yuebin
** @Last Modified time: 2019/11/6 14:03
** @Software: GoLand
****************************************************/
package controllers
import (
"fmt"
"github.com/astaxie/beego"
"github.com/astaxie/beego/logs"
"juhe/service/common"
"juhe/service/controller"
"juhe/service/models"
"strings"
)
type SupplierQuery struct {
beego.Controller
}
func OrderQuery(bankOrderId string) string {
orderInfo := models.GetOrderByBankOrderId(bankOrderId)
if orderInfo.BankOrderId == "" || len(orderInfo.BankOrderId) == 0 {
logs.Error("不存在这样的订单,订单查询结束")
return "不存在这样的订单"
}
if orderInfo.Status != "" && orderInfo.Status != "wait" {
logs.Error(fmt.Sprintf("该订单=%s已经处理完毕", bankOrderId))
return "该订单已经处理完毕"
}
supplierCode := orderInfo.PayProductCode
supplier := controller.GetPaySupplierByCode(supplierCode)
flag := supplier.PayQuery(orderInfo)
if flag {
return "查询完毕,返回正确结果"
} else {
return "订单还在处理中"
}
}
func (c *SupplierQuery) SupplierOrderQuery() {
bankOrderId := strings.TrimSpace(c.GetString("bankOrderId"))
exist := models.BankOrderIdIsEixst(bankOrderId)
keyDataJSON := new(KeyDataJSON)
if !exist {
keyDataJSON.Msg = "该订单不存在"
}
msg := OrderQuery(bankOrderId)
keyDataJSON.Msg = msg
c.Data["json"] = keyDataJSON
c.ServeJSON()
}
/*
* 向上游查询代付结果
*/
func (c *SupplierQuery) SupplierPayForQuery() {
bankOrderId := strings.TrimSpace(c.GetString("bankOrderId"))
keyDataJSON := new(KeyDataJSON)
keyDataJSON.Code = 200
if bankOrderId == "" {
keyDataJSON.Code = -1
keyDataJSON.Msg = "不存在这样的代付订单"
} else {
payFor := models.GetPayForByBankOrderId(bankOrderId)
if payFor.RoadUid == "" {
keyDataJSON.Msg = "该代付订单没有对应的通道uid"
} else {
roadInfo := models.GetRoadInfoByRoadUid(payFor.RoadUid)
supplier := controller.GetPaySupplierByCode(roadInfo.ProductUid)
result, msg := supplier.PayForQuery(payFor)
keyDataJSON.Msg = msg
if result == common.PAYFOR_SUCCESS {
controller.PayForSuccess(payFor)
} else if result == common.PAYFOR_FAIL {
controller.PayForFail(payFor)
} else {
logs.Info("银行处理中")
}
}
}
c.Data["json"] = keyDataJSON
c.ServeJSON()
}

View File

@@ -0,0 +1,75 @@
/***************************************************
** @Desc : This file for ...
** @Time : 2019/12/8 22:15
** @Author : yuebin
** @File : send_notify_merchant
** @Last Modified by : yuebin
** @Last Modified time: 2019/12/8 22:15
** @Software: GoLand
****************************************************/
package controllers
import (
"fmt"
"github.com/astaxie/beego"
"github.com/astaxie/beego/httplib"
"github.com/astaxie/beego/logs"
"juhe/service/common"
"juhe/service/models"
"strings"
)
type SendNotify struct {
beego.Controller
}
func (c *SendNotify) SendNotifyToMerchant() {
bankOrderId := strings.TrimSpace(c.GetString("bankOrderId"))
keyDataJSON := new(KeyDataJSON)
keyDataJSON.Code = -1
orderInfo := models.GetOrderByBankOrderId(bankOrderId)
if orderInfo.Status == common.WAIT {
keyDataJSON.Msg = "该订单不是成功状态,不能回调"
} else {
notifyInfo := models.GetNotifyInfoByBankOrderId(bankOrderId)
notifyUrl := notifyInfo.Url
logs.Info(fmt.Sprintf("boss管理后台手动触发订单回调url=%s", notifyUrl))
req := httplib.Post(notifyUrl)
response, err := req.String()
if err != nil {
logs.Error("回调发送失败fail", err)
keyDataJSON.Msg = fmt.Sprintf("该订单回调发送失败订单回调fail%s", err)
} else {
if !strings.Contains(strings.ToLower(response), "success") {
keyDataJSON.Msg = fmt.Sprintf("该订单回调发送成功但是未返回success字段 商户返回内容=%s", response)
} else {
keyDataJSON.Code = 200
keyDataJSON.Msg = fmt.Sprintf("该订单回调发送成功")
}
}
}
c.Data["json"] = keyDataJSON
c.ServeJSON()
}
func (c *SendNotify) SelfSendNotify() {
bankOrderId := strings.TrimSpace(c.GetString("bankOrderId"))
notifyInfo := models.GetNotifyInfoByBankOrderId(bankOrderId)
keyDataJSON := new(KeyDataJSON)
keyDataJSON.Code = 200
req := httplib.Post(notifyInfo.Url)
response, err := req.String()
if err != nil {
keyDataJSON.Msg = fmt.Sprintf("订单 bankOrderId=%s已经发送回调出错%s", bankOrderId, err)
} else {
keyDataJSON.Msg = fmt.Sprintf("订单 bankOrderId=%s已经发送回调商户返回内容%s", bankOrderId, response)
}
c.Data["json"] = keyDataJSON
c.ServeJSON()
}

View File

@@ -0,0 +1,51 @@
/***************************************************
** @Desc : c file for ...
** @Time : 2019/9/20 14:38
** @Author : yuebin
** @File : test
** @Last Modified by : yuebin
** @Last Modified time: 2019/9/20 14:38
** @Software: GoLand
****************************************************/
package controllers
import (
"github.com/astaxie/beego/httplib"
)
const HOST = "https://gw.open.icbc.com.cn/ui/b2c/pay/transfer/V2"
func (c *BaseController) Test() {
//sign := c.GetString("sign")
msg_id := c.GetString("msg_id")
app_id := c.GetString("app_id")
sign_type := c.GetString("sign_type")
timestamp := c.GetString("timestamp")
//host := HOST + "&sign=" + sign + "&msg_id=" + msg_id + "&app_id=" + app_id + "&sign_type=" + sign_type + "&timestamp=" + timestamp
biz_content := c.GetString("biz_content")
clientType := c.GetString("clientType")
interfaceVersion := c.GetString("interfaceVersion")
interfaceName := c.GetString("interfaceName")
notify_url := c.GetString("notify_url")
ca := c.GetString("ca")
req := httplib.Post(HOST)
//req.Header("ContentType", "application/xwwwformurlencoded")
req.Header("charset", "GBK")
req.Param("charset", "UTF-8")
req.Param("format", "json")
req.Param("sign", "ERERERERERERERE")
req.Param("msg_id", msg_id)
req.Param("app_id", app_id)
req.Param("sign_type", sign_type)
req.Param("timestamp", timestamp)
req.Param("biz_content", biz_content)
req.Param("clientType", clientType)
req.Param("interfaceVersion", interfaceVersion)
req.Param("interfaceName", interfaceName)
req.Param("notify_url", notify_url)
req.Param("ca", ca)
res, _ := req.String()
c.Ctx.WriteString(res)
c.ServeJSON()
}

View File

@@ -0,0 +1,592 @@
/***************************************************
** @Desc : c file for ...
** @Time : 2019/8/16 9:49
** @Author : yuebin
** @File : update
** @Last Modified by : yuebin
** @Last Modified time: 2019/8/16 9:49
** @Software: GoLand
****************************************************/
package controllers
import (
"fmt"
"github.com/astaxie/beego/logs"
"github.com/astaxie/beego/validation"
"juhe/service/common"
"juhe/service/controller"
"juhe/service/models"
"juhe/service/utils"
"strconv"
"strings"
)
type UpdateController struct {
BaseController
}
/*
*更新密码
*/
func (c *UpdateController) UpdatePassword() {
oldPassword := c.GetString("oldPassword")
newPassword := c.GetString("newPassword")
twicePassword := c.GetString("twicePassword")
userID, ok := c.GetSession("userID").(string)
dataJSON := new(KeyDataJSON)
dataJSON.Code = -1
if !ok || userID == "" {
dataJSON.Code = 404
dataJSON.Msg = "请重新登录!"
} else {
userInfo := models.GetUserInfoByUserID(userID)
valid := validation.Validation{}
if userInfo.Passwd != utils.GetMD5Upper(oldPassword) {
dataJSON.Key = ".old-error"
dataJSON.Msg = "输入密码不正确"
} else if v := valid.Min(len(newPassword), 8, ".new-error"); !v.Ok {
dataJSON.Key = v.Error.Key
dataJSON.Msg = "新密码长度必须大于等于8个字符!"
} else if v := valid.Max(len(newPassword), 16, ".new-error"); !v.Ok {
dataJSON.Key = v.Error.Key
dataJSON.Msg = "新密码长度不能大于16个字符!"
} else if v := valid.AlphaNumeric(newPassword, ".new-error"); !v.Ok {
dataJSON.Key = v.Error.Key
dataJSON.Msg = "新密码必须有数字和字母组成!"
} else if newPassword != twicePassword {
dataJSON.Key = ".twice-error"
dataJSON.Msg = "两次密码不一致!"
} else {
dataJSON.Code = 200
dataJSON.Msg = "密码修改成功!"
//删除原先的session状态
c.DelSession("userID")
//更新数据库的密码
userInfo.Passwd = utils.GetMD5Upper(newPassword)
models.UpdateUserInfoPassword(userInfo)
}
}
c.GenerateJSON(dataJSON)
}
/*
* 更新菜单的排列顺序
*/
func (c *UpdateController) UpMenu() {
menuUid := c.GetString("menuUid")
menuInfo := models.GetMenuInfoByMenuUid(menuUid)
dataJSON := new(BaseDataJSON)
if menuInfo.MenuUid == "" {
dataJSON.Msg = "更改排列顺序失败"
dataJSON.Code = -1
} else {
exist := models.MenuOrderIsExists(menuInfo.MenuOrder - 1)
if !exist {
dataJSON.Msg = "已经是最高的顺序"
dataJSON.Code = -1
} else {
//如果他前面有菜单那么交换他们的menuOrder
preMenuInfo := models.GetMenuInfoByMenuOrder(menuInfo.MenuOrder - 1)
menuInfo.MenuOrder = menuInfo.MenuOrder - 1
preMenuInfo.MenuOrder = preMenuInfo.MenuOrder + 1
preMenuInfo.UpdateTime = utils.GetBasicDateTime()
menuInfo.UpdateTime = utils.GetBasicDateTime()
//更新菜单表
models.UpdateMenuInfo(preMenuInfo)
models.UpdateMenuInfo(menuInfo)
//更新二级菜单表
SortSecondMenuOrder(preMenuInfo)
SortSecondMenuOrder(menuInfo)
dataJSON.Code = 200
}
}
c.GenerateJSON(dataJSON)
}
func (c *UpdateController) DownMenu() {
menuUid := c.GetString("menuUid")
menuInfo := models.GetMenuInfoByMenuUid(menuUid)
dataJSON := new(BaseDataJSON)
if menuInfo.MenuUid == "" {
dataJSON.Msg = "更改排列顺序失败"
dataJSON.Code = -1
} else {
exist := models.MenuOrderIsExists(menuInfo.MenuOrder + 1)
if !exist {
dataJSON.Msg = "已经是最高的顺序"
dataJSON.Code = -1
} else {
//如果他前面有菜单那么交换他们的menuOrder
lastMenuInfo := models.GetMenuInfoByMenuOrder(menuInfo.MenuOrder + 1)
menuInfo.MenuOrder = menuInfo.MenuOrder + 1
lastMenuInfo.MenuOrder = lastMenuInfo.MenuOrder - 1
lastMenuInfo.UpdateTime = utils.GetBasicDateTime()
menuInfo.UpdateTime = utils.GetBasicDateTime()
//更新菜单表
models.UpdateMenuInfo(lastMenuInfo)
models.UpdateMenuInfo(menuInfo)
//更新二级菜单表
SortSecondMenuOrder(lastMenuInfo)
SortSecondMenuOrder(menuInfo)
dataJSON.Code = 200
}
}
c.GenerateJSON(dataJSON)
}
/*
* 提升二级菜单的顺序号
*/
func (c *UpdateController) UpSecondMenu() {
secondMenuUid := c.GetString("secondMenuUid")
secondMenuInfo := models.GetSecondMenuInfoBySecondMenuUid(secondMenuUid)
dataJSON := new(BaseDataJSON)
if secondMenuInfo.MenuOrder == 1 {
dataJSON.Code = -1
} else {
preSecondMenuInfo := models.GetSecondMenuInfoByMenuOrder(secondMenuInfo.MenuOrder-1, secondMenuInfo.FirstMenuUid)
preSecondMenuInfo.MenuOrder = preSecondMenuInfo.MenuOrder + 1
preSecondMenuInfo.UpdateTime = utils.GetBasicDateTime()
secondMenuInfo.MenuOrder = secondMenuInfo.MenuOrder - 1
secondMenuInfo.UpdateTime = utils.GetBasicDateTime()
//更新二级菜单项
models.UpdateSecondMenu(preSecondMenuInfo)
models.UpdateSecondMenu(secondMenuInfo)
dataJSON.Code = 200
}
c.GenerateJSON(dataJSON)
}
/*
* 降低二级菜单的顺序号
*/
func (c *UpdateController) DownSecondMenu() {
secondMenuUid := c.GetString("secondMenuUid")
secondMenuInfo := models.GetSecondMenuInfoBySecondMenuUid(secondMenuUid)
dataJSON := new(BaseDataJSON)
l := models.GetSecondMenuLenByFirstMenuUid(secondMenuInfo.FirstMenuUid)
if l == secondMenuInfo.MenuOrder {
dataJSON.Code = -1
} else {
lastSecondMenu := models.GetSecondMenuInfoByMenuOrder(secondMenuInfo.MenuOrder+1, secondMenuInfo.FirstMenuUid)
lastSecondMenu.MenuOrder = lastSecondMenu.MenuOrder - 1
lastSecondMenu.UpdateTime = utils.GetBasicDateTime()
secondMenuInfo.MenuOrder = secondMenuInfo.MenuOrder + 1
secondMenuInfo.UpdateTime = utils.GetBasicDateTime()
models.UpdateSecondMenu(lastSecondMenu)
models.UpdateSecondMenu(secondMenuInfo)
dataJSON.Code = 200
}
c.GenerateJSON(dataJSON)
}
func (c *UpdateController) FreezeOperator() {
userId := strings.TrimSpace(c.GetString("operatorName"))
dataJSON := new(BaseDataJSON)
if models.UpdateStauts("unactive", userId) {
dataJSON.Code = 200
dataJSON.Msg = "冻结成功"
} else {
dataJSON.Code = -1
dataJSON.Msg = "冻结失败"
}
c.GenerateJSON(dataJSON)
}
func (c *UpdateController) UnfreezeOperator() {
userId := strings.TrimSpace(c.GetString("operatorName"))
dataJSON := new(BaseDataJSON)
if models.UpdateStauts("active", userId) {
dataJSON.Code = 200
dataJSON.Msg = "解冻成功"
} else {
dataJSON.Code = -1
dataJSON.Msg = "解冻失败"
}
c.GenerateJSON(dataJSON)
}
func (c *UpdateController) EditOperator() {
userId := strings.TrimSpace(c.GetString("userId"))
password := strings.TrimSpace(c.GetString("password"))
changePassword := strings.TrimSpace(c.GetString("changePassword"))
role := strings.TrimSpace(c.GetString("role"))
nick := strings.TrimSpace(c.GetString("nick"))
remark := strings.TrimSpace(c.GetString("remark"))
keyDataJSON := new(KeyDataJSON)
if (len(password) > 0 || len(changePassword) > 0) && password != changePassword {
keyDataJSON.Code = -1
keyDataJSON.Key = ".veritfy-operator-password-error"
keyDataJSON.Msg = "*2次密码输入不一致"
c.GenerateJSON(keyDataJSON)
}
if role == "" || role == "none" {
keyDataJSON.Code = -1
keyDataJSON.Key = ".change-operator-role-error"
keyDataJSON.Msg = "*角色不能为空"
c.GenerateJSON(keyDataJSON)
}
userInfo := models.GetUserInfoByUserID(userId)
if userInfo.UserId == "" {
keyDataJSON.Code = -2
keyDataJSON.Msg = "该用户不存在"
} else {
userInfo.UpdateTime = utils.GetBasicDateTime()
userInfo.Remark = remark
roleInfo := models.GetRoleByRoleUid(role)
userInfo.RoleName = roleInfo.RoleName
userInfo.Role = role
if len(password) > 0 && len(changePassword) > 0 && password == changePassword {
userInfo.Passwd = utils.GetMD5Upper(password)
}
userInfo.Nick = nick
models.UpdateUserInfo(userInfo)
keyDataJSON.Code = 200
}
c.GenerateJSON(keyDataJSON)
}
/*
* 更新通道的状态
*/
func (c *UpdateController) UpdateRoadStatus() {
roadUid := strings.TrimSpace(c.GetString("roadUid"))
dataJSON := new(BaseDataJSON)
dataJSON.Code = 200
roadInfo := models.GetRoadInfoByRoadUid(roadUid)
if roadInfo.Status == "active" {
roadInfo.Status = "unactive"
} else {
roadInfo.Status = "active"
}
if models.UpdateRoadInfo(roadInfo) {
dataJSON.Code = 200
} else {
dataJSON.Code = -1
}
c.GenerateJSON(dataJSON)
}
/*
* 冻结商户
*/
func (c *UpdateController) UpdateMerchantStatus() {
merchantUid := strings.TrimSpace(c.GetString("merchantUid"))
keyDataJSON := new(KeyDataJSON)
if merchantUid == "" {
keyDataJSON.Code = -1
c.GenerateJSON(keyDataJSON)
return
}
merchantInfo := models.GetMerchantByUid(merchantUid)
if merchantInfo.MerchantUid == "" {
keyDataJSON.Code = -1
c.GenerateJSON(keyDataJSON)
return
}
if merchantInfo.Status == "active" {
merchantInfo.Status = "unactive"
} else {
merchantInfo.Status = "active"
}
merchantInfo.UpdateTime = utils.GetBasicDateTime()
if models.UpdateMerchant(merchantInfo) {
keyDataJSON.Code = 200
} else {
keyDataJSON.Code = -1
}
c.GenerateJSON(keyDataJSON)
}
/*
* 更新账户的状态
*/
func (c *UpdateController) UpdateAccountStatus() {
accountUid := strings.TrimSpace(c.GetString("accountUid"))
accountInfo := models.GetAccountByUid(accountUid)
if accountInfo.Status == "active" {
accountInfo.Status = "unactive"
} else {
accountInfo.Status = "active"
}
accountInfo.UpdateTime = utils.GetBasicDateTime()
dataJSON := new(BaseDataJSON)
if models.UpdateAccount(accountInfo) {
dataJSON.Code = 200
dataJSON.Msg = "更新账户状态成功"
} else {
dataJSON.Code = -1
dataJSON.Msg = "更新账户状态失败"
}
c.GenerateJSON(dataJSON)
}
func (c *UpdateController) OperatorAccount() {
accountUid := strings.TrimSpace(c.GetString("accountUid"))
accountOperator := strings.TrimSpace(c.GetString("accountOperator"))
amount := strings.TrimSpace(c.GetString("amount"))
accountDataJSON := new(AccountDataJSON)
switch accountOperator {
case common.PLUS_AMOUNT:
case common.SUB_AMOUNT:
case common.FREEZE_AMOUNT:
case common.UNFREEZE_AMOUNT:
default:
accountDataJSON.Code = -1
}
a, err := strconv.ParseFloat(amount, 64)
if err != nil {
accountDataJSON.Msg = "处理金额输入有误"
}
if accountDataJSON.Code == -1 {
c.GenerateJSON(accountDataJSON)
return
}
msg, flag := models.OperatorAccount(accountUid, accountOperator, a)
if flag {
accountDataJSON.Code = 200
accountDataJSON.Msg = "处理成功,请检查对应账户信息"
accountDataJSON.AccountList = append(accountDataJSON.AccountList, models.GetAccountByUid(accountUid))
} else {
accountDataJSON.Code = -1
accountDataJSON.Msg = msg
}
c.GenerateJSON(accountDataJSON)
}
func (c *UpdateController) UpdateAgentStatus() {
agentUid := strings.TrimSpace(c.GetString("agentUid"))
agentInfo := models.GetAgentInfoByAgentUid(agentUid)
keyDataJSON := new(KeyDataJSON)
if agentInfo.AgentUid == "" {
keyDataJSON.Code = -1
c.GenerateJSON(keyDataJSON)
}
if agentInfo.Status == "active" {
agentInfo.Status = "unactive"
} else {
agentInfo.Status = "active"
}
agentInfo.UpdateTime = utils.GetBasicDateTime()
if models.UpdateAgentInfo(agentInfo) {
keyDataJSON.Code = 200
} else {
keyDataJSON.Code = -1
}
c.GenerateJSON(keyDataJSON)
}
func (c *UpdateController) ResetAgentPassword() {
agentUid := strings.TrimSpace(c.GetString("agentUid"))
newPassword := strings.TrimSpace(c.GetString("newPassword"))
newVertifyPassword := strings.TrimSpace(c.GetString("newVertifyPassword"))
keyDataJSON := new(KeyDataJSON)
keyDataJSON.Code = 200
if agentUid == "" {
keyDataJSON.Code = -2
} else if newPassword == "" {
keyDataJSON.Code = -1
keyDataJSON.Key = "#agent-login-password-error-reset"
keyDataJSON.Msg = " *新密码不能为空"
} else if newVertifyPassword != newPassword {
keyDataJSON.Code = -1
keyDataJSON.Key = "#agent-vertify-password-error-reset"
keyDataJSON.Msg = " *两次密码输入不一致"
}
if keyDataJSON.Code != 200 {
c.GenerateJSON(keyDataJSON)
return
}
agentInfo := models.GetAgentInfoByAgentUid(agentUid)
agentInfo.UpdateTime = utils.GetBasicDateTime()
agentInfo.AgentPassword = utils.GetMD5Upper(newPassword)
if !models.UpdateAgentInfo(agentInfo) {
keyDataJSON.Code = -1
}
c.GenerateJSON(keyDataJSON)
}
/*
* 手动选择了打款通道
*/
func (c *UpdateController) ChoosePayForRoad() {
roadName := strings.TrimSpace(c.GetString("roadName"))
bankOrderId := strings.TrimSpace(c.GetString("bankOrderId"))
remark := strings.TrimSpace(c.GetString("remark"))
confirmType := strings.TrimSpace(c.GetString("confirmType"))
keyDataJSON := new(KeyDataJSON)
keyDataJSON.Code = 200
if confirmType == common.PAYFOR_ROAD && roadName == "" {
keyDataJSON.Msg = "打款通道不能为空"
keyDataJSON.Code = -1
c.GenerateJSON(keyDataJSON)
return
}
payForInfo := models.GetPayForByBankOrderId(bankOrderId)
roadInfo := models.GetRoadInfoByName(roadName)
if payForInfo.Status != common.PAYFOR_COMFRIM {
keyDataJSON.Msg = "结算状态错误,请刷新后确认"
} else {
payForInfo.UpdateTime = utils.GetBasicDateTime()
payForInfo.GiveType = confirmType
if confirmType == common.PAYFOR_REFUSE {
//拒绝打款
payForInfo.Status = common.PAYFOR_FAIL
} else {
payForInfo.Status = common.PAYFOR_SOLVING
}
payForInfo.RoadUid = roadInfo.RoadUid
payForInfo.RoadName = roadInfo.RoadName
payForInfo.Remark = remark
if !models.ForUpdatePayFor(payForInfo) {
keyDataJSON.Code = -1
keyDataJSON.Msg = "更新代付记录失败"
}
}
c.GenerateJSON(keyDataJSON)
}
/*
* 处理打款结果的处理
*/
func (c *UpdateController) ResultPayFor() {
resultType := strings.TrimSpace(c.GetString("resultType"))
bankOrderId := strings.TrimSpace(c.GetString("bankOrderId"))
keyDataJSON := new(KeyDataJSON)
keyDataJSON.Code = 200
if resultType == "" || bankOrderId == "" {
keyDataJSON.Code = -1
keyDataJSON.Msg = "提交的数据有误"
c.GenerateJSON(keyDataJSON)
return
}
payFor := models.GetPayForByBankOrderId(bankOrderId)
if payFor.Type == common.SELF_HELP {
//如果是管理员在后台提现,不用做任何的商户减款,只需要更新代付订单状态
payFor.UpdateTime = utils.GetBasicDateTime()
payFor.Status = resultType
if !models.ForUpdatePayFor(payFor) {
keyDataJSON.Code = -1
keyDataJSON.Msg = "系统处理失败"
}
c.GenerateJSON(keyDataJSON)
return
}
if payFor.Status == common.PAYFOR_FAIL || payFor.Status == common.PAYFOR_SUCCESS {
logs.Error(fmt.Sprintf("该代付订单=%s状态有误....", bankOrderId))
keyDataJSON.Code = -1
keyDataJSON.Msg = "订单状态有误,请刷新重新判断"
c.GenerateJSON(keyDataJSON)
return
}
if resultType == common.PAYFOR_FAIL {
//处理代付失败的逻辑,减去相应的代付冻结金额
if !controller.PayForFail(payFor) {
logs.Error(fmt.Sprintf("商户uid=%s,处理代付失败逻辑出错", payFor.MerchantUid))
keyDataJSON.Msg = "代付失败逻辑,处理失败"
keyDataJSON.Code = -1
}
} else if resultType == common.PAYFOR_SUCCESS {
//代付成功,减去相应的代付冻结金额,并且余额减掉,可用金额减掉
if !controller.PayForSuccess(payFor) {
logs.Error(fmt.Sprintf("商户uid=%s,处理代付成功逻辑出错", payFor.MerchantUid))
keyDataJSON.Msg = "代付成功逻辑,处理失败"
keyDataJSON.Code = -1
}
}
if keyDataJSON.Code == 200 {
keyDataJSON.Msg = "处理成功"
}
c.GenerateJSON(keyDataJSON)
}
func (c *UpdateController) UpdateOrderStatus() {
bankOrderId := strings.TrimSpace(c.GetString("bankOrderId"))
solveType := strings.TrimSpace(c.GetString("solveType"))
keyDataJSON := new(KeyDataJSON)
orderInfo := models.GetOrderByBankOrderId(bankOrderId)
if orderInfo.BankOrderId == "" {
logs.Error("该订单不存在,bankOrderId=", bankOrderId)
keyDataJSON.Code = -1
} else {
paySolve := new(controller.PaySolveController)
flag := false
switch solveType {
case common.SUCCESS:
flag = paySolve.SolvePaySuccess(bankOrderId, orderInfo.FactAmount, common.SUCCESS)
case common.FAIL:
flag = paySolve.SolvePayFail(orderInfo, common.FAIL)
case common.FREEZE_AMOUNT:
//将这笔订单进行冻结
flag = paySolve.SolveOrderFreeze(bankOrderId)
case common.UNFREEZE_AMOUNT:
//将这笔订单金额解冻
flag = paySolve.SolveOrderUnfreeze(bankOrderId)
case common.REFUND:
if orderInfo.Status == common.SUCCESS {
flag = paySolve.SolveRefund(bankOrderId)
}
case common.ORDERROLL:
if orderInfo.Status == common.SUCCESS {
flag = paySolve.SolveOrderRoll(bankOrderId)
}
default:
logs.Error("不存在这样的处理类型")
}
if flag {
keyDataJSON.Code = 200
} else {
keyDataJSON.Code = -1
}
}
c.GenerateJSON(keyDataJSON)
}

BIN
jhboss/jhboss Normal file

Binary file not shown.

1754
jhboss/jhboss.2019-12-17.log Normal file

File diff suppressed because it is too large Load Diff

2143
jhboss/jhboss.log Normal file

File diff suppressed because it is too large Load Diff

17
jhboss/main.go Normal file
View File

@@ -0,0 +1,17 @@
package main
import (
"github.com/astaxie/beego"
"github.com/astaxie/beego/logs"
_ "juhe/jhboss/routers"
_ "juhe/service/message_queue"
_ "juhe/service/models"
"juhe/service/service_init"
)
func main() {
//设置日志打印
logs.SetLogger(logs.AdapterFile, `{"filename":"jhboss.log", "level":7, "daily":true, "maxdays":10}`)
service_init.InitAll()
beego.Run()
}

105
jhboss/routers/router.go Normal file
View File

@@ -0,0 +1,105 @@
package routers
import (
"github.com/astaxie/beego"
"juhe/jhboss/controllers"
)
func init() {
//beego.Router("/", &controllers.PageController{}, "*:Index")
//添加过滤函数
beego.Router("/filter.html", &controllers.FilterController{}, "*:Filter")
//登录验证接口
beego.Router("/login", &controllers.LoginController{}, "*:Login")
beego.Router("/logout", &controllers.LoginController{}, "*:Logout")
beego.Router("/getVerifyImg", &controllers.LoginController{}, "*:GetVerifyImg")
beego.Router("/update/password", &controllers.UpdateController{}, "*:UpdatePassword")
beego.Router("/freeze/operator", &controllers.UpdateController{}, "*:FreezeOperator")
beego.Router("/freeze/merchant", &controllers.UpdateController{}, "*:UpdateMerchantStatus")
beego.Router("/unfreeze/operator", &controllers.UpdateController{}, "*:UnfreezeOperator")
beego.Router("/unfreeze/merchant", &controllers.UpdateController{}, "*:UpdateMerchantStatus")
beego.Router("/edit/operator", &controllers.UpdateController{}, "*:EditOperator")
beego.Router("/add/menu", &controllers.AddController{}, "*:AddMenu")
beego.Router("/add/secondMenu", &controllers.AddController{}, "*:AddSecondMenu")
beego.Router("/add/power", &controllers.AddController{}, "*:AddPower")
beego.Router("/add/role", &controllers.AddController{}, "*:AddRole")
beego.Router("/add/operator", &controllers.AddController{}, "*:AddOperator")
beego.Router("/add/bankCard", &controllers.AddController{}, "*:AddBankCard")
beego.Router("/add/road", &controllers.AddController{}, "*:AddRoad")
beego.Router("/add/roadPool", &controllers.AddController{}, "*:AddRoadPool")
beego.Router("/add/merchant", &controllers.AddController{}, "*:AddMerchant")
beego.Router("/add/agent", &controllers.AddController{}, "*:AddAgent")
beego.Router("/add/merchant/deploy", &controllers.AddController{}, "*:AddMerchantDeploy")
beego.Router("/add/merchant/payType", &controllers.AddController{}, "*:AddMerchantPayType")
beego.Router("/add/payfor", &controllers.AddController{}, "*:AddPayFor")
beego.Router("/add/self/payfor", &controllers.AddController{}, "*:AddSelfPayFor")
beego.Router("/get/menu", &controllers.GetController{}, "*:GetMenu")
beego.Router("/get/secondMenu", &controllers.GetController{}, "*:GetSecondMenu")
beego.Router("/get/secondMenus", &controllers.GetController{}, "*:GetSecondMenus")
beego.Router("/get/oneMenu", &controllers.GetController{}, "*:GetOneMenu")
beego.Router("/get/firstMenu", &controllers.GetController{}, "*:GetFirstMenu")
beego.Router("/get/powerItem", &controllers.GetController{}, "*:GetPowerItem")
beego.Router("/get/role", &controllers.GetController{}, "*:GetRole")
beego.Router("/get/allRole", &controllers.GetController{}, "*:GetAllRole")
beego.Router("/get/deployTree", &controllers.GetController{}, "*:GetDeployTree")
beego.Router("/get/operator", &controllers.GetController{}, "*:GetOperator")
beego.Router("/get/oneOperator", &controllers.GetController{}, "*:GetOneOperator")
beego.Router("/get/editOperator", &controllers.GetController{}, "*:GetEditOperator")
beego.Router("/get/bankCard", &controllers.GetController{}, "*:GetBankCard")
beego.Router("/get/oneBankCard", &controllers.GetController{}, "*:GetOneBankCard")
beego.Router("/get/road", &controllers.GetController{}, "*:GetRoad")
beego.Router("/get/oneRoad", &controllers.GetController{}, "*:GetOneRoad")
beego.Router("/get/all/road", &controllers.GetController{}, "*:GetAllRoad")
beego.Router("/get/roadPool", &controllers.GetController{}, "*:GetRoadPool")
beego.Router("/get/all/roll/pool", &controllers.GetController{}, "*:GetAllRollPool")
beego.Router("/get/merchant", &controllers.GetController{}, "*:GetMerchant")
beego.Router("/get/all/merchant", &controllers.GetController{}, "*:GetAllMerchant")
beego.Router("/get/one/merchant", &controllers.GetController{}, "*:GetOneMerchant")
beego.Router("/get/one/merchant/deploy", &controllers.GetController{}, "*:GetOneMerchantDeploy")
beego.Router("/get/all/account", &controllers.GetController{}, "*:GetAllAccount")
beego.Router("/get/account", &controllers.GetController{}, "*:GetAccount")
beego.Router("/get/one/account", &controllers.GetController{}, "*:GetOneAccount")
beego.Router("/get/account/history", &controllers.GetController{}, "*:GetAccountHistory")
beego.Router("/get/agent", &controllers.GetController{}, "*:GetAgent")
beego.Router("/get/all/agent", &controllers.GetController{}, "*:GetAllAgent")
beego.Router("/get/product", &controllers.GetController{}, "*:GetProduct")
beego.Router("/get/order", &controllers.GetController{}, "*:GetOrder")
beego.Router("/get/one/order", &controllers.GetController{}, "*:GetOneOrder")
beego.Router("/get/orderProfit", &controllers.GetController{}, "*:GetOrderProfit")
beego.Router("/get/payfor", &controllers.GetController{}, "*:GetPayFor")
beego.Router("/get/one/payfor", &controllers.GetController{}, "*:GetOnePayFor")
beego.Router("/get/balance", &controllers.GetController{}, "*:GetBalance")
beego.Router("/get/notify/bankOrderId/list", &controllers.GetController{}, "*:GetNotifyBankOrderIdList")
beego.Router("/get/agent/to/merchant", &controllers.GetController{}, "*:GetAgentToMerchant")
beego.Router("/get/profit", &controllers.GetController{}, "*:GetProfit")
beego.Router("/save/power", &controllers.AddController{}, "*:SavePower")
beego.Router("/save/roadUid", &controllers.AddController{}, "*:SaveRoadUid")
beego.Router("/up/menu", &controllers.UpdateController{}, "*:UpMenu")
beego.Router("/down/menu", &controllers.UpdateController{}, "*:DownMenu")
beego.Router("/up/secondMenu", &controllers.UpdateController{}, "*:UpSecondMenu")
beego.Router("/down/secondMenu", &controllers.UpdateController{}, "*:DownSecondMenu")
beego.Router("/update/roadStatus", &controllers.UpdateController{}, "*:UpdateRoadStatus")
beego.Router("/update/account/status", &controllers.UpdateController{}, "*:UpdateAccountStatus")
beego.Router("/update/agent/status", &controllers.UpdateController{}, "*:UpdateAgentStatus")
beego.Router("/update/order/status", &controllers.UpdateController{}, "*:UpdateOrderStatus")
beego.Router("/account/operator", &controllers.UpdateController{}, "*:OperatorAccount")
beego.Router("/delete/menu", &controllers.Deletecontroller{}, "*:DeleteMenu")
beego.Router("/delete/secondMenu", &controllers.Deletecontroller{}, "*:DeleteSecondMenu")
beego.Router("/delete/powerItem", &controllers.Deletecontroller{}, "*:DeletePowerItem")
beego.Router("/delete/role", &controllers.Deletecontroller{}, "*:DeleteRole")
beego.Router("/delete/operator", &controllers.Deletecontroller{}, "*:DeleteOperator")
beego.Router("/delete/bankCardRecord", &controllers.Deletecontroller{}, "*:DeleteBankCardRecord")
beego.Router("/delete/road", &controllers.Deletecontroller{}, "*:DeleteRoad")
beego.Router("/delete/roadPool", &controllers.Deletecontroller{}, "*:DeleteRoadPool")
beego.Router("/delete/merchant", &controllers.Deletecontroller{}, "*:DeleteMerchant")
beego.Router("/delete/account", &controllers.Deletecontroller{}, "*:DeleteAccount")
beego.Router("/delete/agent", &controllers.Deletecontroller{}, "*:DeleteAgent")
beego.Router("/delete/agent/merchant/relation", &controllers.Deletecontroller{}, "*:DeleteAgentRelation")
beego.Router("/reset/agent/password", &controllers.UpdateController{}, "*:ResetAgentPassword")
beego.Router("/supplier/order/query", &controllers.SupplierQuery{}, "*:SupplierOrderQuery")
beego.Router("/supplier/payfor/query", &controllers.SupplierQuery{}, "*:SupplierPayForQuery")
beego.Router("/choose/payfor/road", &controllers.UpdateController{}, "*:ChoosePayForRoad")
beego.Router("/result/payfor", &controllers.UpdateController{}, "*:ResultPayFor")
beego.Router("/send/notify", &controllers.SendNotify{}, "*:SendNotifyToMerchant")
beego.Router("/self/send/notify", &controllers.SendNotify{}, "*:SelfSendNotify")
}

View File

@@ -0,0 +1,48 @@
/***************************************************
** @Desc : This file for ...
** @Time : 2019/10/23 15:17
** @Author : yuebin
** @File : router_pages
** @Last Modified by : yuebin
** @Last Modified time: 2019/10/23 15:17
** @Software: GoLand
****************************************************/
package routers
import (
"github.com/astaxie/beego"
"juhe/jhboss/controllers"
)
func init() {
beego.Router("/", &controllers.PageController{}, "*:Index")
beego.Router("/index.html", &controllers.PageController{}, "*:Index")
beego.Router("/login.html", &controllers.PageController{}, "*:LoginPage")
beego.Router("/account.html", &controllers.PageController{}, "*:AccountPage")
beego.Router("/account_history.html", &controllers.PageController{}, "*:AccountHistoryPage")
beego.Router("/bank_card.html", &controllers.PageController{}, "*:BankCardPage")
beego.Router("/create_agent.html", &controllers.PageController{}, "*:CreateAgentPage")
beego.Router("/edit_role.html", &controllers.PageController{}, "*:EditRolePage")
beego.Router("/first_menu.html", &controllers.PageController{}, "*:FirstMenuPage")
beego.Router("/main.html", &controllers.PageController{}, "*:MainPage")
beego.Router("/menu.html", &controllers.PageController{}, "*:MenuPage")
beego.Router("/merchant.html", &controllers.PageController{}, "*:MerchantPage")
beego.Router("/operator.html", &controllers.PageController{}, "*:OperatorPage")
beego.Router("/power.html", &controllers.PageController{}, "*:PowerPage")
beego.Router("/road.html", &controllers.PageController{}, "*:RoadPage")
beego.Router("/road_pool.html", &controllers.PageController{}, "*:RoadPoolPage")
beego.Router("/road_profit.html", &controllers.PageController{}, "*:RoadProfitPage")
beego.Router("/role.html", &controllers.PageController{}, "*:RolePage")
beego.Router("/second_menu.html", &controllers.PageController{}, "*:SecondMenuPage")
beego.Router("/order_info.html", &controllers.PageController{}, "*:OrderInfoPage")
beego.Router("/order_profit.html", &controllers.PageController{}, "*:OrderProfitPage")
beego.Router("/merchant_payfor.html", &controllers.PageController{}, "*:MerchantPayforPage")
beego.Router("/self_payfor.html", &controllers.PageController{}, "*:SelfPayforPage")
beego.Router("/payfor_record.html", &controllers.PageController{}, "*:PayforRecordPage")
beego.Router("/confirm.html", &controllers.PageController{}, "*:ConfirmPage")
beego.Router("/self_notify.html", &controllers.PageController{}, "*:SelfNotifyPage")
beego.Router("/self_plus_sub.html", &controllers.PageController{}, "*:SelfPlusSubPage")
beego.Router("/agent_to_merchant.html", &controllers.PageController{}, "*:AgentToMerchantPage")
beego.Router("/platform_profit.html", &controllers.PageController{}, "*:PlatFormProfitPage")
beego.Router("/agent_profit.html", &controllers.PageController{}, "*:AgentProfitPage")
}

181
jhboss/static/css/basic.css Normal file
View File

@@ -0,0 +1,181 @@
/* 公共样式文件 */
input {
padding-left: 10px;
}
.margin-top-20 {
margin-top: 20px;
}
.color-red {
color: red;
}
.text-center {
text-align: center;
}
a {
text-decoration: none;
}
ul li {
list-style: none;
}
li {
list-style: none;
}
.row {
margin-left: 0px;
margin-right: 0px;
}
.modal-body .input-group {
margin-bottom: 20px;
}
.basic-addon3 {
font-size: 14px;
color: green;
}
.select-content {
display: inline-block;
margin-right: 20px;
}
.select-content select {
width: 210px;
height: 30px;
text-align: center;
text-align-last: center;
padding-left: 5px;
}
.first-input-group .first-menu-error {
display: inline-block;
margin-left: 20px;
padding-top: 6px;
color: red;
}
.table-caption {
color: red;
font-size: 12px;
}
.add-menu {
text-decoration: center;
}
.add-menu strong {
/* padding-bottom: 4px; */
color: skyblue;
}
.add-button {
margin-left: 10px;
margin-bottom: 10px;
margin-right: 30px;
}
.main {
padding-left: 10px;
}
.menu-table table {
width: 100%;
}
.menu-table table tbody tr:hover{
background-color: #e7e7e7;
}
.menu-table table tr th {
text-align: center;
border: 1px solid #e7e7e7;
}
.menu-table table tbody tr th {
font-size: 12px;
font-weight: normal;
}
.menu-table table button {
height: 30px;
}
.cut_page {
line-height: 30px;
text-align: center;
margin-top: 20px;
height: 30px;
width:100%;
background-color: skyblue;
border-radius: 5px;
}
.cut_page li {
display: inline-block;
margin: 0;
padding: 0;
}
.cut_page .pre_page:hover {
color: blue;
cursor:pointer;
}
.cut_page .next_page:hover {
color: blue;
cursor: pointer;
}
.cut_page li input {
background-color: #e7e7e7;
height: 25px;
width: 40px;
padding: 5px;
outline: none;
}
.cut_page li button {
height: 25px;
width: 50px;
margin: 0 auto;
/* text-align: center; */
line-height: 10px;
outline: none;
}
.cut_page li select {
background-color: #e7e7e7;
}
.search {
margin-bottom: 10px;
padding: 10px;
border-bottom: 1px solid #e7e7e7;
}
.search div {
display: inline;
margin-right: 20px;
}
.search div{
text-align: center;
}
.star {
color: red;
font-size: 16px;
margin-right: 30px;
}
fieldset {
padding: 3px;
margin: 0 0 10px 0;
border: 1px dotted #b8d0d6;
}
fieldset legend {
border: 0;
font-size: 12px;
font-weight: 700;
margin-bottom: 5px;
}

253
jhboss/static/css/login.css Normal file
View File

@@ -0,0 +1,253 @@
html, body, div, span, applet, object, iframe,
h1, h2, h3, h4, h5, h6, p, blockquote, pre,
a, abbr, acronym, address, big, cite, code,
del, dfn, em, img, ins, kbd, q, s, samp,
small, strike, strong, sub, sup, tt, var,
b, u, i, center,
dl, dt, dd, ol, ul, li,
fieldset, form, label, legend,
table, caption, tbody, tfoot, thead, tr, th, td,
article, aside, canvas, details, embed,
figure, figcaption, footer, header, hgroup,
menu, nav, output, ruby, section, summary,
time, mark, audio, video {
margin: 0;
padding: 0;
border: 0;
font-size: 100%;
font: inherit;
vertical-align: baseline;
}
article, aside, details, figcaption, figure,
footer, header, hgroup, menu, nav, section {
display: block;
}
body {
line-height: 1;
}
ol, ul {
list-style: none;
}
blockquote, q {
quotes: none;
}
blockquote:before, blockquote:after,
q:before, q:after {
content: '';
content: none;
}
table {
border-collapse: collapse;
border-spacing: 0;
}
/*
* Copyright (c) 2012-2013 Thibaut Courouble
* http://www.cssflow.com
*
* Licensed under the MIT License:
* http://www.opensource.org/licenses/mit-license.php
*/
body {
font: 13px/20px 'Lucida Grande', Tahoma, Verdana, sans-serif;
color: #404040;
background: #f3f3f3;
}
.container {
margin: 100px auto;
width: 640px;
}
.login {
overflow: hidden;
position: relative;
margin: 0 auto;
padding: 20px 20px 20px;
width: 310px;
background: white;
border-radius: 3px;
-webkit-box-shadow: 0 0 200px rgba(255, 255, 255, 0.5), 0 1px 2px rgba(0, 0, 0, 0.3);
box-shadow: 20px 20px 200px rgba(255, 255, 255, 0.5), 0 1px 2px rgba(0, 0, 0, 0.3);
}
.login:before {
content: '';
position: absolute;
top: -8px;
right: -8px;
bottom: -8px;
left: -8px;
z-index: -1;
background: rgba(0, 0, 0, 0.08);
border-radius: 4px;
}
.login h1 {
margin: -20px -20px 21px;
line-height: 40px;
font-size: 15px;
font-weight: bold;
color: #555;
text-align: center;
text-shadow: 0 1px white;
background: #f3f3f3;
border-bottom: 1px solid #cfcfcf;
border-radius: 3px 3px 0 0;
/*background-image: -webkit-linear-gradient(top, whiteffd, #eef2f5);*/
/*background-image: -moz-linear-gradient(top, whiteffd, #eef2f5);*/
/*background-image: -o-linear-gradient(top, whiteffd, #eef2f5);*/
/*background-image: linear-gradient(to bottom, whiteffd, #eef2f5);*/
-webkit-box-shadow: 0 1px whitesmoke;
box-shadow: 0 1px whitesmoke;
}
.login p {
margin: 20px 0 0;
}
.login p:first-child {
margin-top: 0;
}
.login input[type=text], .login input[type=password] {
width: 278px;
}
.login .verifyText {
overflow: hidden;
margin-top: 20px;
}
.login .verify .verifyText {
overflow: hidden;
width: 160px;
}
.login .verify .verifyImg {
overflow: hidden;
display: block;
width: 110px;
height: 36px;
margin-top: 20px;
}
.login .verify .verifyImg:hover {
cursor: pointer;
}
.left_f {
float: left;
}
.right_f {
float: right;
}
.login .remember_me {
position: absolute;
bottom: 10px;
line-height: 31px;
}
.login div.remember_me label {
font-size: 12px;
color: #777;
cursor: pointer;
}
.login div.remember_me input {
position: relative;
bottom: 1px;
margin-right: 4px;
vertical-align: middle;
}
.login div.submit {
text-align: right;
}
.login-help {
margin: 20px 0;
font-size: 11px;
color: white;
text-align: center;
text-shadow: 0 1px #2a85a1;
font-size:12px;
}
.login-help a {
color: #cce7fa;
text-decoration: none;
}
.login-help a:hover {
text-decoration: underline;
}
:-moz-placeholder {
color: #c9c9c9 !important;
font-size: 13px;
}
::-webkit-input-placeholder {
color: #ccc;
font-size: 13px;
}
input {
font-family: 'Lucida Grande', Tahoma, Verdana, sans-serif;
font-size: 14px;
}
input[type=text], input[type=password] {
margin: 5px;
padding: 0 10px;
width: 200px;
height: 34px;
color: #404040;
background: white;
border: 1px solid;
border-color: #c4c4c4 #d1d1d1 #d4d4d4;
border-radius: 2px;
outline: 5px solid #eff4f7;
-moz-outline-radius: 3px;
-webkit-box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.12);
box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.12);
}
input[type=text]:focus, input[type=password]:focus {
border-color: #7dc9e2;
outline-color: #dceefc;
outline-offset: 0;
}
input[type=submit] {
margin-top: 20px;
padding: 0 18px;
height: 29px;
font-size: 12px;
font-weight: bold;
color: #527881;
text-shadow: 0 1px #e3f1f1;
background: #cde5ef;
border: 1px solid;
border-color: #b4ccce #b3c0c8 #9eb9c2;
border-radius: 16px;
outline: 0;
cursor: pointer;
-webkit-box-sizing: content-box;
-moz-box-sizing: content-box;
box-sizing: content-box;
background-image: -webkit-linear-gradient(top, #edf5f8, #cde5ef);
background-image: -moz-linear-gradient(top, #edf5f8, #cde5ef);
background-image: -o-linear-gradient(top, #edf5f8, #cde5ef);
background-image: linear-gradient(to bottom, #edf5f8, #cde5ef);
-webkit-box-shadow: inset 0 1px white, 0 1px 2px rgba(0, 0, 0, 0.15);
box-shadow: inset 0 1px white, 0 1px 2px rgba(0, 0, 0, 0.15);
}
input[type=submit]:active {
background: #cde5ef;
border-color: #9eb9c2 #b3c0c8 #b4ccce;
-webkit-box-shadow: inset 0 0 3px rgba(0, 0, 0, 0.2);
box-shadow: inset 0 0 3px rgba(0, 0, 0, 0.2);
}
.lt-ie9 input[type=text], .lt-ie9 input[type=password] {
line-height: 34px;
}

116
jhboss/static/js/basic.js Normal file
View File

@@ -0,0 +1,116 @@
/**************************************时间格式化处理************************************/
function dateFtt(fmt,date)
{ //author: meizz
var o = {
"M+" : date.getMonth()+1, //月份
"d+" : date.getDate(), //日
"h+" : date.getHours(), //小时
"m+" : date.getMinutes(), //分
"s+" : date.getSeconds(), //秒
"q+" : Math.floor((date.getMonth()+3)/3), //季度
"S" : date.getMilliseconds() //毫秒
};
if(/(y+)/.test(fmt))
fmt=fmt.replace(RegExp.$1, (date.getFullYear()+"").substr(4 - RegExp.$1.length));
for(var k in o)
if(new RegExp("("+ k +")").test(fmt))
fmt = fmt.replace(RegExp.$1, (RegExp.$1.length==1) ? (o[k]) : (("00"+ o[k]).substr((""+ o[k]).length)));
return fmt;
}
$(".start-time").on('changeDate', function() {
let startTime = $(".start-time").val();
if (startTime) {
$(".end-time").datetimepicker("setStartDate", startTime);
} else {
$(".end-time").datetimepicker("setStartDate", new Date(-8639968443048000));
}
});
$("#end-time").on('changeDate', function() {
let endTime = $(".end-time").val();
if (endTime) {
$(".start-time").datetimepicker('setEndDate', endTime);
} else {
$(".start-time").datetimepicker();
}
});
$(".start-time, .end-time").datetimepicker({
language: 'zh-CN',
format: "yyyy-mm-dd hh:ii:00",
clearBtn: true,
todayBtn: true,
autoclose: true,
startView:2,
minView: 0,//最低视图 小时视图
maxView: 4, //最高视图 十年视图
showSecond : true,
showHours : true,
minuteStep:1
});
//将上游通道供应商写入
function setSupplier() {
$.ajax({
url: "/get/product",
success: function (res) {
if (res.Code == 404) {window.parent.location = "/login.html";}
else if (res.Code == -1) {alert("没有获取到上游供应商数据");}
else {
let str = '<option value="' + "" + '">' + "请选择" + '</option>';
for (let key in res.ProductMap) {
let v = res.ProductMap[key];
str = str + '<option value="' + key + '">' + v + '</option>'
}
$("#search-order-supplier-name").html(str);
}
},
error: function () {
alert("系统异常,请稍后再试");
}
});
}
//动态获取商户名
function setMerchant() {
$.ajax({
url:"/get/all/merchant",
data:{},
success: function (res) {
let str = '<option value="' + "" + '">' + "请选择" + '</option>';
for (let i = 0; i < res.MerchantList.length; i ++) {
let merchant = res.MerchantList[i];
str = str + '<option value="' + merchant.MerchantUid + '">' + merchant.MerchantName + '</option>';
}
$("#select-merchant-name").html(str);
},
error: function () {
alert("系统异常,请稍后再试");
}
});
}
//动态获取代理名称
function setAgent() {
$.ajax({
url: "/get/all/agent",
data:{},
success:function (res) {
if (res.Code == 404) {
window.parent.location = "/login.html";
} else {
let str = '<option value="' + "" + '">' + "请选择" + '</option>';
for (let i = 0; i < res.AgentList.length; i ++) {
let agent = res.AgentList[i];
str = str + '<option value="' + agent.AgentUid + '">' + agent.AgentName + '</option>';
}
$("#select-agent-name").html(str);
}
},
error: function () {
alert("系统异常,请稍后再试")
}
});
}

View File

@@ -0,0 +1,27 @@
function filter() {
$.ajax({
url: "/filter.html",
success: function(res) {
let loc = window.location.toString();
if (res.Code == 404) {
if (loc.indexOf("login.html") !== -1) {
return;
}
window.parent.location = "/login.html";
} else if (res.Code == 200) {
if (loc.indexOf("login.html") !== -1) {
window.parent.location = "/index.html";
}
}
},
error: function(e) {
window.parent.location = "/login.html";
}
});
};
$().ready(function() {
filter();
});

4
jhboss/static/js/jquery.min.js vendored Normal file

File diff suppressed because one or more lines are too long

12
jhboss/static/js/jquery.ui.min.js vendored Normal file

File diff suppressed because one or more lines are too long

View File

@@ -0,0 +1,22 @@
# Auto detect text files and perform LF normalization
* text=auto
# Custom for Visual Studio
*.cs diff=csharp
*.sln merge=union
*.csproj merge=union
*.vbproj merge=union
*.fsproj merge=union
*.dbproj merge=union
# Standard to msysgit
*.doc diff=astextplain
*.DOC diff=astextplain
*.docx diff=astextplain
*.DOCX diff=astextplain
*.dot diff=astextplain
*.DOT diff=astextplain
*.pdf diff=astextplain
*.PDF diff=astextplain
*.rtf diff=astextplain
*.RTF diff=astextplain

View File

@@ -0,0 +1,5 @@
node_modules/
.idea
*.iml
atlassian-ide-plugin.xml
yuicompressor-*

View File

@@ -0,0 +1,30 @@
{
"bitwise": false,
"camelcase": false,
"curly": false,
"eqeqeq": true,
"es3": false,
"forin": false,
"freeze": false,
"immed": false,
"sub": true,
"latedef": false,
"newcap": false,
"noarg": false,
"node": true,
"laxbreak": true,
"noempty": true,
"varstmt": false,
"nonbsp": true,
"nonew": false,
"plusplus": false,
"quotmark": "single",
"undef": true,
"unused": true,
"esversion": 6,
"strict": false,
"trailing": true,
"browser": false,
"asi": true,
"predef": ["window","document","jQuery","define"]
}

View File

@@ -0,0 +1,9 @@
# PHP Storm
.idea
*.iml
atlassian-ide-plugin.xml
yuicompressor-*
build
less
sample*
screenshot

View File

@@ -0,0 +1,5 @@
sudo: false
before_script:
- cd ./tests
- echo "new Date().toString();" | phantomjs
script: phantomjs run-qunit.js tests.html

View File

@@ -0,0 +1,25 @@
module.exports = (grunt) => {
require('load-grunt-tasks')(grunt)
grunt.initConfig({
pkg: grunt.file.readJSON('package.json'),
jshint: {
options: {
jshintrc: '.jshintrc'
},
all: {
src: ['./js/bootstrap-datetimepicker.js']
}
},
versioncheck: {
target: {
options: {
hideUpToDate: true
}
}
}
})
grunt.registerTask('default', ['jshint', 'versioncheck'])
}

View File

@@ -0,0 +1,201 @@
Apache License
Version 2.0, January 2004
http://www.apache.org/licenses/
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
1. Definitions.
"License" shall mean the terms and conditions for use, reproduction,
and distribution as defined by Sections 1 through 9 of this document.
"Licensor" shall mean the copyright owner or entity authorized by
the copyright owner that is granting the License.
"Legal Entity" shall mean the union of the acting entity and all
other entities that control, are controlled by, or are under common
control with that entity. For the purposes of this definition,
"control" means (i) the power, direct or indirect, to cause the
direction or management of such entity, whether by contract or
otherwise, or (ii) ownership of fifty percent (50%) or more of the
outstanding shares, or (iii) beneficial ownership of such entity.
"You" (or "Your") shall mean an individual or Legal Entity
exercising permissions granted by this License.
"Source" form shall mean the preferred form for making modifications,
including but not limited to software source code, documentation
source, and configuration files.
"Object" form shall mean any form resulting from mechanical
transformation or translation of a Source form, including but
not limited to compiled object code, generated documentation,
and conversions to other media types.
"Work" shall mean the work of authorship, whether in Source or
Object form, made available under the License, as indicated by a
copyright notice that is included in or attached to the work
(an example is provided in the Appendix below).
"Derivative Works" shall mean any work, whether in Source or Object
form, that is based on (or derived from) the Work and for which the
editorial revisions, annotations, elaborations, or other modifications
represent, as a whole, an original work of authorship. For the purposes
of this License, Derivative Works shall not include works that remain
separable from, or merely link (or bind by name) to the interfaces of,
the Work and Derivative Works thereof.
"Contribution" shall mean any work of authorship, including
the original version of the Work and any modifications or additions
to that Work or Derivative Works thereof, that is intentionally
submitted to Licensor for inclusion in the Work by the copyright owner
or by an individual or Legal Entity authorized to submit on behalf of
the copyright owner. For the purposes of this definition, "submitted"
means any form of electronic, verbal, or written communication sent
to the Licensor or its representatives, including but not limited to
communication on electronic mailing lists, source code control systems,
and issue tracking systems that are managed by, or on behalf of, the
Licensor for the purpose of discussing and improving the Work, but
excluding communication that is conspicuously marked or otherwise
designated in writing by the copyright owner as "Not a Contribution."
"Contributor" shall mean Licensor and any individual or Legal Entity
on behalf of whom a Contribution has been received by Licensor and
subsequently incorporated within the Work.
2. Grant of Copyright License. Subject to the terms and conditions of
this License, each Contributor hereby grants to You a perpetual,
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
copyright license to reproduce, prepare Derivative Works of,
publicly display, publicly perform, sublicense, and distribute the
Work and such Derivative Works in Source or Object form.
3. Grant of Patent License. Subject to the terms and conditions of
this License, each Contributor hereby grants to You a perpetual,
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
(except as stated in this section) patent license to make, have made,
use, offer to sell, sell, import, and otherwise transfer the Work,
where such license applies only to those patent claims licensable
by such Contributor that are necessarily infringed by their
Contribution(s) alone or by combination of their Contribution(s)
with the Work to which such Contribution(s) was submitted. If You
institute patent litigation against any entity (including a
cross-claim or counterclaim in a lawsuit) alleging that the Work
or a Contribution incorporated within the Work constitutes direct
or contributory patent infringement, then any patent licenses
granted to You under this License for that Work shall terminate
as of the date such litigation is filed.
4. Redistribution. You may reproduce and distribute copies of the
Work or Derivative Works thereof in any medium, with or without
modifications, and in Source or Object form, provided that You
meet the following conditions:
(a) You must give any other recipients of the Work or
Derivative Works a copy of this License; and
(b) You must cause any modified files to carry prominent notices
stating that You changed the files; and
(c) You must retain, in the Source form of any Derivative Works
that You distribute, all copyright, patent, trademark, and
attribution notices from the Source form of the Work,
excluding those notices that do not pertain to any part of
the Derivative Works; and
(d) If the Work includes a "NOTICE" text file as part of its
distribution, then any Derivative Works that You distribute must
include a readable copy of the attribution notices contained
within such NOTICE file, excluding those notices that do not
pertain to any part of the Derivative Works, in at least one
of the following places: within a NOTICE text file distributed
as part of the Derivative Works; within the Source form or
documentation, if provided along with the Derivative Works; or,
within a display generated by the Derivative Works, if and
wherever such third-party notices normally appear. The contents
of the NOTICE file are for informational purposes only and
do not modify the License. You may add Your own attribution
notices within Derivative Works that You distribute, alongside
or as an addendum to the NOTICE text from the Work, provided
that such additional attribution notices cannot be construed
as modifying the License.
You may add Your own copyright statement to Your modifications and
may provide additional or different license terms and conditions
for use, reproduction, or distribution of Your modifications, or
for any such Derivative Works as a whole, provided Your use,
reproduction, and distribution of the Work otherwise complies with
the conditions stated in this License.
5. Submission of Contributions. Unless You explicitly state otherwise,
any Contribution intentionally submitted for inclusion in the Work
by You to the Licensor shall be under the terms and conditions of
this License, without any additional terms or conditions.
Notwithstanding the above, nothing herein shall supersede or modify
the terms of any separate license agreement you may have executed
with Licensor regarding such Contributions.
6. Trademarks. This License does not grant permission to use the trade
names, trademarks, service marks, or product names of the Licensor,
except as required for reasonable and customary use in describing the
origin of the Work and reproducing the content of the NOTICE file.
7. Disclaimer of Warranty. Unless required by applicable law or
agreed to in writing, Licensor provides the Work (and each
Contributor provides its Contributions) on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
implied, including, without limitation, any warranties or conditions
of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
PARTICULAR PURPOSE. You are solely responsible for determining the
appropriateness of using or redistributing the Work and assume any
risks associated with Your exercise of permissions under this License.
8. Limitation of Liability. In no event and under no legal theory,
whether in tort (including negligence), contract, or otherwise,
unless required by applicable law (such as deliberate and grossly
negligent acts) or agreed to in writing, shall any Contributor be
liable to You for damages, including any direct, indirect, special,
incidental, or consequential damages of any character arising as a
result of this License or out of the use or inability to use the
Work (including but not limited to damages for loss of goodwill,
work stoppage, computer failure or malfunction, or any and all
other commercial damages or losses), even if such Contributor
has been advised of the possibility of such damages.
9. Accepting Warranty or Additional Liability. While redistributing
the Work or Derivative Works thereof, You may choose to offer,
and charge a fee for, acceptance of support, warranty, indemnity,
or other liability obligations and/or rights consistent with this
License. However, in accepting such obligations, You may act only
on Your own behalf and on Your sole responsibility, not on behalf
of any other Contributor, and only if You agree to indemnify,
defend, and hold each Contributor harmless for any liability
incurred by, or claims asserted against, such Contributor by reason
of your accepting any such warranty or additional liability.
END OF TERMS AND CONDITIONS
APPENDIX: How to apply the Apache License to your work.
To apply the Apache License to your work, attach the following
boilerplate notice, with the fields enclosed by brackets "[]"
replaced with your own identifying information. (Don't include
the brackets!) The text should be enclosed in the appropriate
comment syntax for the file format. We also recommend that a
file or class name and description of purpose be included on the
same "printed page" as the copyright notice for easier
identification within third-party archives.
Copyright 2012 Sebastien MALOT
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.

View File

@@ -0,0 +1,2 @@
# Deprecation warning!
This repository has been deprecated in favour of [this](https://eonasdan.github.io/bootstrap-datetimepicker/).

View File

@@ -0,0 +1,15 @@
{
"name": "smalot-bootstrap-datetimepicker",
"main": ["js/bootstrap-datetimepicker.min.js", "css/bootstrap-datetimepicker.min.css"],
"ignore": [
"build",
"sample in bootstrap v2",
"sample in bootstrap v3",
"screenshot",
"tests",
".gitattributes",
".gitignore",
".travis.yml",
"minify.sh"
]
}

View File

@@ -0,0 +1,66 @@
// Datepicker .less buildfile. Includes select mixins/variables from bootstrap
// and imports the included datepicker.less to output a minimal datepicker.css
//
// Usage:
// lessc build.less datepicker.css
//
// Variables and mixins copied from bootstrap 2.0.2
// Variables
@grayLight: #999;
@grayLighter: #eee;
@white: #fff;
@linkColor: #08c;
@btnPrimaryBackground: @linkColor;
@orange: #f89406;
// Mixins
// Border Radius
.border-radius(@radius: 5px) {
-webkit-border-radius: @radius;
-moz-border-radius: @radius;
border-radius: @radius;
}
// Button backgrounds
.buttonBackground(@startColor, @endColor) {
.gradientBar(@startColor, @endColor);
.reset-filter();
&:hover, &:active, &.active, &.disabled, &[disabled] {
background-color: @endColor;
}
&:active,
&.active {
background-color: darken(@endColor, 10%) e("\9");
}
}
// Reset filters for IE
.reset-filter() {
filter: progid:DXImageTransform.Microsoft.gradient(enabled = false);
}
// Gradient Bar Colors for buttons and alerts
.gradientBar(@primaryColor, @secondaryColor) {
#gradient > .vertical(@primaryColor, @secondaryColor);
border-color: @secondaryColor @secondaryColor darken(@secondaryColor, 15%);
border-color: rgba(0,0,0,.1) rgba(0,0,0,.1) fadein(rgba(0,0,0,.1), 15%);
}
// Gradients
#gradient {
.vertical(@startColor: #555, @endColor: #333) {
background-color: mix(@startColor, @endColor, 60%);
background-image: -moz-linear-gradient(top, @startColor, @endColor); // FF 3.6+
background-image: -ms-linear-gradient(top, @startColor, @endColor); // IE10
background-image: -webkit-gradient(linear, 0 0, 0 100%, from(@startColor), to(@endColor)); // Safari 4+, Chrome 2+
background-image: -webkit-linear-gradient(top, @startColor, @endColor); // Safari 5.1+, Chrome 10+
background-image: -o-linear-gradient(top, @startColor, @endColor); // Opera 11.10
background-image: linear-gradient(top, @startColor, @endColor); // The standard
background-repeat: repeat-x;
filter: e(%("progid:DXImageTransform.Microsoft.gradient(startColorstr='%d', endColorstr='%d', GradientType=0)",@startColor,@endColor)); // IE9 and down
}
}
@import "../less/datetimepicker.less";

View File

@@ -0,0 +1,69 @@
// Datepicker standalone .less buildfile. Includes all necessary mixins/variables/rules from bootstrap
// and imports the included datepicker.less to output a minimal standalone datepicker.css
//
// Usage:
// lessc build_standalone.less datepicker.css
//
// Variables, mixins, and rules copied from bootstrap 2.0.2
@import "build.less";
// Dropdown css
@zindexDropdown: 1000;
@grayDark: #333;
@baseLineHeight: 18px;
@tableBackground: transparent; // overall background-color
@dropdownBackground: @white;
@dropdownBorder: rgba(0,0,0,.2);
@dropdownLinkColor: @grayDark;
@dropdownLinkColorHover: @white;
@dropdownLinkBackgroundHover: @linkColor;
// Drop shadows
.box-shadow(@shadow) {
-webkit-box-shadow: @shadow;
-moz-box-shadow: @shadow;
box-shadow: @shadow;
}
// The dropdown menu (ul)
// ----------------------
.datetimepicker.dropdown-menu {
position: absolute;
top: 100%;
left: 0;
z-index: @zindexDropdown;
float: left;
display: none; // none by default, but block on "open" of the menu
min-width: 160px;
list-style: none;
background-color: @dropdownBackground;
border: 1px solid #ccc;
border: 1px solid rgba(0,0,0,.2);
.border-radius(5px);
.box-shadow(0 5px 10px rgba(0,0,0,.2));
-webkit-background-clip: padding-box;
-moz-background-clip: padding;
background-clip: padding-box;
*border-right-width: 2px;
*border-bottom-width: 2px;
// Normally inherited from bootstrap's `body`
color: #333333;
font-family: "Helvetica Neue",Helvetica,Arial,sans-serif;
font-size:13px;
line-height: @baseLineHeight;
th, td {
padding: 4px 5px;
}
}
// Alternative arrows
// May require `charset="UTF-8"` in your `<link>` tag
.datetimepicker {
.prev, .next {font-style:normal;}
.prev:after {content:"«";}
.next:after {content:"»";}
}

View File

@@ -0,0 +1,418 @@
/*!
* Datetimepicker for Bootstrap
*
* Copyright 2012 Stefan Petre
* Improvements by Andrew Rowls
* Licensed under the Apache License v2.0
* http://www.apache.org/licenses/LICENSE-2.0
*
*/
.datetimepicker {
padding: 4px;
margin-top: 1px;
-webkit-border-radius: 4px;
-moz-border-radius: 4px;
border-radius: 4px;
direction: ltr;
}
.datetimepicker-inline {
width: 220px;
}
.datetimepicker.datetimepicker-rtl {
direction: rtl;
}
.datetimepicker.datetimepicker-rtl table tr td span {
float: right;
}
.datetimepicker-dropdown, .datetimepicker-dropdown-left {
top: 0;
left: 0;
}
[class*=" datetimepicker-dropdown"]:before {
content: '';
display: inline-block;
border-left: 7px solid transparent;
border-right: 7px solid transparent;
border-bottom: 7px solid #cccccc;
border-bottom-color: rgba(0, 0, 0, 0.2);
position: absolute;
}
[class*=" datetimepicker-dropdown"]:after {
content: '';
display: inline-block;
border-left: 6px solid transparent;
border-right: 6px solid transparent;
border-bottom: 6px solid #ffffff;
position: absolute;
}
[class*=" datetimepicker-dropdown-top"]:before {
content: '';
display: inline-block;
border-left: 7px solid transparent;
border-right: 7px solid transparent;
border-top: 7px solid #cccccc;
border-top-color: rgba(0, 0, 0, 0.2);
border-bottom: 0;
}
[class*=" datetimepicker-dropdown-top"]:after {
content: '';
display: inline-block;
border-left: 6px solid transparent;
border-right: 6px solid transparent;
border-top: 6px solid #ffffff;
border-bottom: 0;
}
.datetimepicker-dropdown-bottom-left:before {
top: -7px;
right: 6px;
}
.datetimepicker-dropdown-bottom-left:after {
top: -6px;
right: 7px;
}
.datetimepicker-dropdown-bottom-right:before {
top: -7px;
left: 6px;
}
.datetimepicker-dropdown-bottom-right:after {
top: -6px;
left: 7px;
}
.datetimepicker-dropdown-top-left:before {
bottom: -7px;
right: 6px;
}
.datetimepicker-dropdown-top-left:after {
bottom: -6px;
right: 7px;
}
.datetimepicker-dropdown-top-right:before {
bottom: -7px;
left: 6px;
}
.datetimepicker-dropdown-top-right:after {
bottom: -6px;
left: 7px;
}
.datetimepicker > div {
display: none;
}
.datetimepicker.minutes div.datetimepicker-minutes {
display: block;
}
.datetimepicker.hours div.datetimepicker-hours {
display: block;
}
.datetimepicker.days div.datetimepicker-days {
display: block;
}
.datetimepicker.months div.datetimepicker-months {
display: block;
}
.datetimepicker.years div.datetimepicker-years {
display: block;
}
.datetimepicker table {
margin: 0;
}
.datetimepicker td,
.datetimepicker th {
text-align: center;
width: 20px;
height: 20px;
-webkit-border-radius: 4px;
-moz-border-radius: 4px;
border-radius: 4px;
border: none;
}
.table-striped .datetimepicker table tr td,
.table-striped .datetimepicker table tr th {
background-color: transparent;
}
.datetimepicker table tr td.minute:hover {
background: #eeeeee;
cursor: pointer;
}
.datetimepicker table tr td.hour:hover {
background: #eeeeee;
cursor: pointer;
}
.datetimepicker table tr td.day:hover {
background: #eeeeee;
cursor: pointer;
}
.datetimepicker table tr td.old,
.datetimepicker table tr td.new {
color: #999999;
}
.datetimepicker table tr td.disabled,
.datetimepicker table tr td.disabled:hover {
background: none;
color: #999999;
cursor: default;
}
.datetimepicker table tr td.today,
.datetimepicker table tr td.today:hover,
.datetimepicker table tr td.today.disabled,
.datetimepicker table tr td.today.disabled:hover {
background-color: #fde19a;
background-image: -moz-linear-gradient(top, #fdd49a, #fdf59a);
background-image: -ms-linear-gradient(top, #fdd49a, #fdf59a);
background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#fdd49a), to(#fdf59a));
background-image: -webkit-linear-gradient(top, #fdd49a, #fdf59a);
background-image: -o-linear-gradient(top, #fdd49a, #fdf59a);
background-image: linear-gradient(to bottom, #fdd49a, #fdf59a);
background-repeat: repeat-x;
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#fdd49a', endColorstr='#fdf59a', GradientType=0);
border-color: #fdf59a #fdf59a #fbed50;
border-color: rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.25);
filter: progid:DXImageTransform.Microsoft.gradient(enabled=false);
}
.datetimepicker table tr td.today:hover,
.datetimepicker table tr td.today:hover:hover,
.datetimepicker table tr td.today.disabled:hover,
.datetimepicker table tr td.today.disabled:hover:hover,
.datetimepicker table tr td.today:active,
.datetimepicker table tr td.today:hover:active,
.datetimepicker table tr td.today.disabled:active,
.datetimepicker table tr td.today.disabled:hover:active,
.datetimepicker table tr td.today.active,
.datetimepicker table tr td.today:hover.active,
.datetimepicker table tr td.today.disabled.active,
.datetimepicker table tr td.today.disabled:hover.active,
.datetimepicker table tr td.today.disabled,
.datetimepicker table tr td.today:hover.disabled,
.datetimepicker table tr td.today.disabled.disabled,
.datetimepicker table tr td.today.disabled:hover.disabled,
.datetimepicker table tr td.today[disabled],
.datetimepicker table tr td.today:hover[disabled],
.datetimepicker table tr td.today.disabled[disabled],
.datetimepicker table tr td.today.disabled:hover[disabled] {
background-color: #fdf59a;
}
.datetimepicker table tr td.today:active,
.datetimepicker table tr td.today:hover:active,
.datetimepicker table tr td.today.disabled:active,
.datetimepicker table tr td.today.disabled:hover:active,
.datetimepicker table tr td.today.active,
.datetimepicker table tr td.today:hover.active,
.datetimepicker table tr td.today.disabled.active,
.datetimepicker table tr td.today.disabled:hover.active {
background-color: #fbf069;
}
.datetimepicker table tr td.active,
.datetimepicker table tr td.active:hover,
.datetimepicker table tr td.active.disabled,
.datetimepicker table tr td.active.disabled:hover {
background-color: #006dcc;
background-image: -moz-linear-gradient(top, #0088cc, #0044cc);
background-image: -ms-linear-gradient(top, #0088cc, #0044cc);
background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#0088cc), to(#0044cc));
background-image: -webkit-linear-gradient(top, #0088cc, #0044cc);
background-image: -o-linear-gradient(top, #0088cc, #0044cc);
background-image: linear-gradient(to bottom, #0088cc, #0044cc);
background-repeat: repeat-x;
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#0088cc', endColorstr='#0044cc', GradientType=0);
border-color: #0044cc #0044cc #002a80;
border-color: rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.25);
filter: progid:DXImageTransform.Microsoft.gradient(enabled=false);
color: #ffffff;
text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.25);
}
.datetimepicker table tr td.active:hover,
.datetimepicker table tr td.active:hover:hover,
.datetimepicker table tr td.active.disabled:hover,
.datetimepicker table tr td.active.disabled:hover:hover,
.datetimepicker table tr td.active:active,
.datetimepicker table tr td.active:hover:active,
.datetimepicker table tr td.active.disabled:active,
.datetimepicker table tr td.active.disabled:hover:active,
.datetimepicker table tr td.active.active,
.datetimepicker table tr td.active:hover.active,
.datetimepicker table tr td.active.disabled.active,
.datetimepicker table tr td.active.disabled:hover.active,
.datetimepicker table tr td.active.disabled,
.datetimepicker table tr td.active:hover.disabled,
.datetimepicker table tr td.active.disabled.disabled,
.datetimepicker table tr td.active.disabled:hover.disabled,
.datetimepicker table tr td.active[disabled],
.datetimepicker table tr td.active:hover[disabled],
.datetimepicker table tr td.active.disabled[disabled],
.datetimepicker table tr td.active.disabled:hover[disabled] {
background-color: #0044cc;
}
.datetimepicker table tr td.active:active,
.datetimepicker table tr td.active:hover:active,
.datetimepicker table tr td.active.disabled:active,
.datetimepicker table tr td.active.disabled:hover:active,
.datetimepicker table tr td.active.active,
.datetimepicker table tr td.active:hover.active,
.datetimepicker table tr td.active.disabled.active,
.datetimepicker table tr td.active.disabled:hover.active {
background-color: #003399;
}
.datetimepicker table tr td span {
display: block;
width: 23%;
height: 54px;
line-height: 54px;
float: left;
margin: 1%;
cursor: pointer;
-webkit-border-radius: 4px;
-moz-border-radius: 4px;
border-radius: 4px;
}
.datetimepicker .datetimepicker-hours span {
height: 26px;
line-height: 26px;
}
.datetimepicker .datetimepicker-hours table tr td span.hour_am,
.datetimepicker .datetimepicker-hours table tr td span.hour_pm {
width: 14.6%;
}
.datetimepicker .datetimepicker-hours fieldset legend,
.datetimepicker .datetimepicker-minutes fieldset legend {
margin-bottom: inherit;
line-height: 30px;
}
.datetimepicker .datetimepicker-minutes span {
height: 26px;
line-height: 26px;
}
.datetimepicker table tr td span:hover {
background: #eeeeee;
}
.datetimepicker table tr td span.disabled,
.datetimepicker table tr td span.disabled:hover {
background: none;
color: #999999;
cursor: default;
}
.datetimepicker table tr td span.active,
.datetimepicker table tr td span.active:hover,
.datetimepicker table tr td span.active.disabled,
.datetimepicker table tr td span.active.disabled:hover {
background-color: #006dcc;
background-image: -moz-linear-gradient(top, #0088cc, #0044cc);
background-image: -ms-linear-gradient(top, #0088cc, #0044cc);
background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#0088cc), to(#0044cc));
background-image: -webkit-linear-gradient(top, #0088cc, #0044cc);
background-image: -o-linear-gradient(top, #0088cc, #0044cc);
background-image: linear-gradient(to bottom, #0088cc, #0044cc);
background-repeat: repeat-x;
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#0088cc', endColorstr='#0044cc', GradientType=0);
border-color: #0044cc #0044cc #002a80;
border-color: rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.25);
filter: progid:DXImageTransform.Microsoft.gradient(enabled=false);
color: #ffffff;
text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.25);
}
.datetimepicker table tr td span.active:hover,
.datetimepicker table tr td span.active:hover:hover,
.datetimepicker table tr td span.active.disabled:hover,
.datetimepicker table tr td span.active.disabled:hover:hover,
.datetimepicker table tr td span.active:active,
.datetimepicker table tr td span.active:hover:active,
.datetimepicker table tr td span.active.disabled:active,
.datetimepicker table tr td span.active.disabled:hover:active,
.datetimepicker table tr td span.active.active,
.datetimepicker table tr td span.active:hover.active,
.datetimepicker table tr td span.active.disabled.active,
.datetimepicker table tr td span.active.disabled:hover.active,
.datetimepicker table tr td span.active.disabled,
.datetimepicker table tr td span.active:hover.disabled,
.datetimepicker table tr td span.active.disabled.disabled,
.datetimepicker table tr td span.active.disabled:hover.disabled,
.datetimepicker table tr td span.active[disabled],
.datetimepicker table tr td span.active:hover[disabled],
.datetimepicker table tr td span.active.disabled[disabled],
.datetimepicker table tr td span.active.disabled:hover[disabled] {
background-color: #0044cc;
}
.datetimepicker table tr td span.active:active,
.datetimepicker table tr td span.active:hover:active,
.datetimepicker table tr td span.active.disabled:active,
.datetimepicker table tr td span.active.disabled:hover:active,
.datetimepicker table tr td span.active.active,
.datetimepicker table tr td span.active:hover.active,
.datetimepicker table tr td span.active.disabled.active,
.datetimepicker table tr td span.active.disabled:hover.active {
background-color: #003399;
}
.datetimepicker table tr td span.old {
color: #999999;
}
.datetimepicker th.switch {
width: 145px;
}
.datetimepicker th span.glyphicon {
pointer-events: none;
}
.datetimepicker thead tr:first-child th,
.datetimepicker tfoot th {
cursor: pointer;
}
.datetimepicker thead tr:first-child th:hover,
.datetimepicker tfoot th:hover {
background: #eeeeee;
}
.input-append.date .add-on i,
.input-prepend.date .add-on i,
.input-group.date .input-group-addon span {
cursor: pointer;
width: 14px;
height: 14px;
}

File diff suppressed because one or more lines are too long

File diff suppressed because it is too large Load Diff

File diff suppressed because one or more lines are too long

View File

@@ -0,0 +1,17 @@
/**
* Arabic translation for bootstrap-datetimepicker
* Ala' Mohammad <amohammad@birzeit.ecu>
*/
;(function($){
$.fn.datetimepicker.dates['ar'] = {
days: ["الأحد", "الاثنين", "الثلاثاء", "الأربعاء", "الخميس", "الجمعة", "السبت", "الأحد"],
daysShort: ["أحد", "اثنين", "ثلاثاء", "أربعاء", "خميس", "جمعة", "سبت", "أحد"],
daysMin: ["أح", "إث", "ث", "أر", "خ", "ج", "س", "أح"],
months: ["يناير", "فبراير", "مارس", "أبريل", "مايو", "يونيو", "يوليو", "أغسطس", "سبتمبر", "أكتوبر", "نوفمبر", "ديسمبر"],
monthsShort: ["يناير", "فبراير", "مارس", "أبريل", "مايو", "يونيو", "يوليو", "أغسطس", "سبتمبر", "أكتوبر", "نوفمبر", "ديسمبر"],
today: "هذا اليوم",
suffix: [],
meridiem: [],
rtl: true
};
}(jQuery));

View File

@@ -0,0 +1,16 @@
/**
* Azerbaijani translation for bootstrap-datetimepicker
* Konstantin Kaluzhnikov <k.kaluzhnikov@gmail.com>
*/
;(function($){
$.fn.datetimepicker.dates['az'] = {
days: ["Bazar", "Bazar ertəsi", "Çərşənbə axşamı", "Çərşənbə", "Cümə axşamı", "Cümə", "Şənbə", "Bazar"],
daysShort: ["B", "Be", "Ça", "Ç", "Ca", "C", "Ş", "B"],
daysMin: ["B", "Be", "Ça", "Ç", "Ca", "C", "Ş", "B"],
months: ["Yanvar", "Fevral", "Mart", "Aprel", "May", "İyun", "İyul", "Avqust", "Sentyabr", "Oktyabr", "Noyabr", "Dekabr"],
monthsShort: ["Yan", "Fev", "Mar", "Apr", "May", "İyun", "İyul", "Avq", "Sen", "Okt", "Noy", "Dek"],
today: "Bugün",
suffix: [],
meridiem: []
};
}(jQuery));

View File

@@ -0,0 +1,16 @@
/**
* Bulgarian translation for bootstrap-datetimepicker
* Apostol Apostolov <apostol.s.apostolov@gmail.com>
*/
;(function($){
$.fn.datetimepicker.dates['bg'] = {
days: ["Неделя", "Понеделник", "Вторник", "Сряда", "Четвъртък", "Петък", "Събота", "Неделя"],
daysShort: ["Нед", "Пон", "Вто", "Сря", "Чет", "Пет", "Съб", "Нед"],
daysMin: ["Н", "П", "В", "С", "Ч", "П", "С", "Н"],
months: ["Януари", "Февруари", "Март", "Април", "Май", "Юни", "Юли", "Август", "Септември", "Октомври", "Ноември", "Декември"],
monthsShort: ["Ян", "Фев", "Мар", "Апр", "Май", "Юни", "Юли", "Авг", "Сеп", "Окт", "Ное", "Дек"],
today: "днес",
suffix: [],
meridiem: []
};
}(jQuery));

View File

@@ -0,0 +1,16 @@
/**
* Bangla(Bangladesh) translation for bootstrap-datetimepicker
* Mahbub Rabbani <mahbub [dot] rucse [at] gmail.com>
*/
;(function($){
$.fn.datetimepicker.dates['bn'] = {
days: ["রবিবার", "সোমবার", "মঙ্গলবার", "বুধবার", "বৃহষ্পতিবার", "শুক্রবার", "শনিবার", "রবিবার"],
daysShort: ["রবি", "সোম", "মঙ্গল", "বুধ", " বৃহঃ", "শুক্র", "শনি", "রবি"],
daysMin: ["রবি", "সোম", "মঙ্গ", "বুধ", "বৃহ", "শুক্র", "শনি", "রবি"],
months: ['জানুয়ারী', 'ফেব্রুয়ারী', 'মার্চ', 'এপ্রিল', 'মে', 'জুন', 'জুলাই', 'অগাস্ট', 'সেপ্টেম্বর', 'অক্টোবর', 'নভেম্বর', 'ডিসেম্বর' ],
monthsShort: ['জানু', 'ফেব্রু', 'মার্চ', 'এপ্রি', 'মে', 'জুন', 'জুলা', 'অগা', 'সেপ্টে', 'অক্টো', 'নভে', 'ডিসে' ],
today: "আজ",
suffix: [],
meridiem: ['পূর্বাহ্ণ', 'অপরাহ্ন']
};
}(jQuery));

View File

@@ -0,0 +1,16 @@
/**
* Catalan translation for bootstrap-datetimepicker
* J. Garcia <jogaco.en@gmail.com>
*/
;(function($){
$.fn.datetimepicker.dates['ca'] = {
days: ["Diumenge", "Dilluns", "Dimarts", "Dimecres", "Dijous", "Divendres", "Dissabte", "Diumenge"],
daysShort: ["Diu", "Dil", "Dmt", "Dmc", "Dij", "Div", "Dis", "Diu"],
daysMin: ["dg", "dl", "dt", "dc", "dj", "dv", "ds", "dg"],
months: ["Gener", "Febrer", "Març", "Abril", "Maig", "Juny", "Juliol", "Agost", "Setembre", "Octubre", "Novembre", "Desembre"],
monthsShort: ["Gen", "Feb", "Mar", "Abr", "Mai", "Jun", "Jul", "Ago", "Set", "Oct", "Nov", "Des"],
today: "Avui",
suffix: [],
meridiem: []
};
}(jQuery));

View File

@@ -0,0 +1,19 @@
/**
* Czech translation for bootstrap-datetimepicker
* Matěj Koubík <matej@koubik.name>
* Fixes by Michal Remiš <michal.remis@gmail.com>
*/
;(function($){
$.fn.datetimepicker.dates['cs'] = {
days: ["Neděle", "Pondělí", "Úterý", "Středa", "Čtvrtek", "Pátek", "Sobota", "Neděle"],
daysShort: ["Ned", "Pon", "Úte", "Stř", "Čtv", "Pát", "Sob", "Ned"],
daysMin: ["Ne", "Po", "Út", "St", "Čt", "Pá", "So", "Ne"],
months: ["Leden", "Únor", "Březen", "Duben", "Květen", "Červen", "Červenec", "Srpen", "Září", "Říjen", "Listopad", "Prosinec"],
monthsShort: ["Led", "Úno", "Bře", "Dub", "Kvě", "Čer", "Čnc", "Srp", "Zář", "Říj", "Lis", "Pro"],
today: "Dnes",
suffix: [],
meridiem: [],
weekStart: 1,
format: "dd.mm.yyyy"
};
}(jQuery));

View File

@@ -0,0 +1,16 @@
/**
* Danish translation for bootstrap-datetimepicker
* Christian Pedersen <http://github.com/chripede>
*/
;(function($){
$.fn.datetimepicker.dates['da'] = {
days: ["Søndag", "Mandag", "Tirsdag", "Onsdag", "Torsdag", "Fredag", "Lørdag", "Søndag"],
daysShort: ["Søn", "Man", "Tir", "Ons", "Tor", "Fre", "Lør", "Søn"],
daysMin: ["Sø", "Ma", "Ti", "On", "To", "Fr", "Lø", "Sø"],
months: ["Januar", "Februar", "Marts", "April", "Maj", "Juni", "Juli", "August", "September", "Oktober", "November", "December"],
monthsShort: ["Jan", "Feb", "Mar", "Apr", "Maj", "Jun", "Jul", "Aug", "Sep", "Okt", "Nov", "Dec"],
today: "I Dag",
suffix: [],
meridiem: []
};
}(jQuery));

View File

@@ -0,0 +1,18 @@
/**
* German translation for bootstrap-datetimepicker
* Sam Zurcher <sam@orelias.ch>
*/
;(function($){
$.fn.datetimepicker.dates['de'] = {
days: ["Sonntag", "Montag", "Dienstag", "Mittwoch", "Donnerstag", "Freitag", "Samstag", "Sonntag"],
daysShort: ["Son", "Mon", "Die", "Mit", "Don", "Fre", "Sam", "Son"],
daysMin: ["So", "Mo", "Di", "Mi", "Do", "Fr", "Sa", "So"],
months: ["Januar", "Februar", "März", "April", "Mai", "Juni", "Juli", "August", "September", "Oktober", "November", "Dezember"],
monthsShort: ["Jan", "Feb", "Mär", "Apr", "Mai", "Jun", "Jul", "Aug", "Sep", "Okt", "Nov", "Dez"],
today: "Heute",
suffix: [],
meridiem: [],
weekStart: 1,
format: "dd.mm.yyyy"
};
}(jQuery));

View File

@@ -0,0 +1,18 @@
/**
* Estonian translation for bootstrap-datetimepicker
* Rene Korss <http://rene.korss.ee>
*/
;(function($){
$.fn.datetimepicker.dates['ee'] = {
days: ["Pühapäev", "Esmaspäev", "Teisipäev", "Kolmapäev", "Neljapäev", "Reede", "Laupäev", "Pühapäev"],
daysShort: ["P", "E", "T", "K", "N", "R", "L", "P"],
daysMin: ["P", "E", "T", "K", "N", "R", "L", "P"],
months: ["Jaanuar", "Veebruar", "Märts", "Aprill", "Mai", "Juuni", "Juuli", "August", "September", "Oktoober", "November", "Detsember"],
monthsShort: ["Jaan", "Veebr", "Märts", "Apr", "Mai", "Juuni", "Juuli", "Aug", "Sept", "Okt", "Nov", "Dets"],
today: "Täna",
suffix: [],
meridiem: [],
weekStart: 1,
format: "dd.mm.yyyy hh:ii"
};
}(jQuery));

View File

@@ -0,0 +1,15 @@
/**
* Greek translation for bootstrap-datetimepicker
*/
;(function($){
$.fn.datetimepicker.dates['el'] = {
days: ["Κυριακή", "Δευτέρα", "Τρίτη", "Τετάρτη", "Πέμπτη", "Παρασκευή", "Σάββατο", "Κυριακή"],
daysShort: ["Κυρ", "Δευ", "Τρι", "Τετ", "Πεμ", "Παρ", "Σαβ", "Κυρ"],
daysMin: ["Κυ", "Δε", "Τρ", "Τε", "Πε", "Πα", "Σα", "Κυ"],
months: ["Ιανουάριος", "Φεβρουάριος", "Μάρτιος", "Απρίλιος", "Μάιος", "Ιούνιος", "Ιούλιος", "Αύγουστος", "Σεπτέμβριος", "Οκτώβριος", "Νοέμβριος", "Δεκέμβριος"],
monthsShort: ["Ιαν", "Φεβ", "Μαρ", "Απρ", "Μάι", "Ιουν", "Ιουλ", "Αυγ", "Σεπ", "Οκτ", "Νοε", "Δεκ"],
today: "Σήμερα",
suffix: [],
meridiem: []
};
}(jQuery));

View File

@@ -0,0 +1,16 @@
/**
* Spanish translation for bootstrap-datetimepicker
* Bruno Bonamin <bruno.bonamin@gmail.com>
*/
;(function($){
$.fn.datetimepicker.dates['es'] = {
days: ["Domingo", "Lunes", "Martes", "Miércoles", "Jueves", "Viernes", "Sábado", "Domingo"],
daysShort: ["Dom", "Lun", "Mar", "Mié", "Jue", "Vie", "Sáb", "Dom"],
daysMin: ["Do", "Lu", "Ma", "Mi", "Ju", "Vi", "Sa", "Do"],
months: ["Enero", "Febrero", "Marzo", "Abril", "Mayo", "Junio", "Julio", "Agosto", "Septiembre", "Octubre", "Noviembre", "Diciembre"],
monthsShort: ["Ene", "Feb", "Mar", "Abr", "May", "Jun", "Jul", "Ago", "Sep", "Oct", "Nov", "Dic"],
today: "Hoy",
suffix: [],
meridiem: []
};
}(jQuery));

View File

@@ -0,0 +1,16 @@
/**
* Finnish translation for bootstrap-datetimepicker
* Jaakko Salonen <https://github.com/jsalonen>
*/
;(function($){
$.fn.datetimepicker.dates['fi'] = {
days: ["sunnuntai", "maanantai", "tiistai", "keskiviikko", "torstai", "perjantai", "lauantai", "sunnuntai"],
daysShort: ["sun", "maa", "tii", "kes", "tor", "per", "lau", "sun"],
daysMin: ["su", "ma", "ti", "ke", "to", "pe", "la", "su"],
months: ["tammikuu", "helmikuu", "maaliskuu", "huhtikuu", "toukokuu", "kesäkuu", "heinäkuu", "elokuu", "syyskuu", "lokakuu", "marraskuu", "joulukuu"],
monthsShort: ["tam", "hel", "maa", "huh", "tou", "kes", "hei", "elo", "syy", "lok", "mar", "jou"],
today: "tänään",
suffix: [],
meridiem: []
};
}(jQuery));

View File

@@ -0,0 +1,18 @@
/**
* French translation for bootstrap-datetimepicker
* Nico Mollet <nico.mollet@gmail.com>
*/
;(function($){
$.fn.datetimepicker.dates['fr'] = {
days: ["Dimanche", "Lundi", "Mardi", "Mercredi", "Jeudi", "Vendredi", "Samedi", "Dimanche"],
daysShort: ["Dim", "Lun", "Mar", "Mer", "Jeu", "Ven", "Sam", "Dim"],
daysMin: ["D", "L", "Ma", "Me", "J", "V", "S", "D"],
months: ["Janvier", "Février", "Mars", "Avril", "Mai", "Juin", "Juillet", "Août", "Septembre", "Octobre", "Novembre", "Décembre"],
monthsShort: ["Jan", "Fev", "Mar", "Avr", "Mai", "Jui", "Jul", "Aou", "Sep", "Oct", "Nov", "Dec"],
today: "Aujourd'hui",
suffix: [],
meridiem: ["am", "pm"],
weekStart: 1,
format: "dd/mm/yyyy hh:ii"
};
}(jQuery));

View File

@@ -0,0 +1,17 @@
/**
* Hebrew translation for bootstrap-datetimepicker
* Sagie Maoz <sagie@maoz.info>
*/
;(function($){
$.fn.datetimepicker.dates['he'] = {
days: ["ראשון", "שני", "שלישי", "רביעי", "חמישי", "שישי", "שבת", "ראשון"],
daysShort: ["א", "ב", "ג", "ד", "ה", "ו", "ש", "א"],
daysMin: ["א", "ב", "ג", "ד", "ה", "ו", "ש", "א"],
months: ["ינואר", "פברואר", "מרץ", "אפריל", "מאי", "יוני", "יולי", "אוגוסט", "ספטמבר", "אוקטובר", "נובמבר", "דצמבר"],
monthsShort: ["ינו", "פבר", "מרץ", "אפר", "מאי", "יונ", "יול", "אוג", "ספט", "אוק", "נוב", "דצמ"],
today: "היום",
suffix: [],
meridiem: [],
rtl: true
};
}(jQuery));

View File

@@ -0,0 +1,15 @@
/**
* Croatian localisation
*/
;(function($){
$.fn.datetimepicker.dates['hr'] = {
days: ["Nedjelja", "Ponedjelja", "Utorak", "Srijeda", "Četrtak", "Petak", "Subota", "Nedjelja"],
daysShort: ["Ned", "Pon", "Uto", "Srr", "Čet", "Pet", "Sub", "Ned"],
daysMin: ["Ne", "Po", "Ut", "Sr", "Če", "Pe", "Su", "Ne"],
months: ["Siječanj", "Veljača", "Ožujak", "Travanj", "Svibanj", "Lipanj", "Srpanj", "Kolovoz", "Rujan", "Listopad", "Studeni", "Prosinac"],
monthsShort: ["Sije", "Velj", "Ožu", "Tra", "Svi", "Lip", "Jul", "Kol", "Ruj", "Lis", "Stu", "Pro"],
today: "Danas",
suffix: [],
meridiem: []
};
}(jQuery));

View File

@@ -0,0 +1,17 @@
/**
* Hungarian translation for bootstrap-datetimepicker
* darevish <http://github.com/darevish>
*/
;(function($){
$.fn.datetimepicker.dates['hu'] = {
days: ["Vasárnap", "Hétfő", "Kedd", "Szerda", "Csütörtök", "Péntek", "Szombat", "Vasárnap"],
daysShort: ["Vas", "Hét", "Ked", "Sze", "Csü", "Pén", "Szo", "Vas"],
daysMin: ["V", "H", "K", "Sze", "Cs", "P", "Szo", "V"],
months: ["Január", "Február", "Március", "Április", "Május", "Június", "Július", "Augusztus", "Szeptember", "Október", "November", "December"],
monthsShort: ["Jan", "Feb", "Már", "Ápr", "Máj", "Jún", "Júl", "Aug", "Sze", "Okt", "Nov", "Dec"],
today: "Ma",
suffix: [],
meridiem: [],
weekStart: 1
};
}(jQuery));

View File

@@ -0,0 +1,16 @@
/**
* Armenian translation for bootstrap-datepicker
* Hayk Chamyan <hamshen@gmail.com>
*/
;(function($){
$.fn.datetimepicker.dates['hy'] = {
days: ["Կիրակի", "Երկուշաբթի", "Երեքշաբթի", "Չորեքշաբթի", "Հինգշաբթի", "Ուրբաթ", "Շաբաթ", "Կիրակի"],
daysShort: ["Կիր", "Երկ", "Երք", "Չոր", "Հնգ", "Ուր", "Շաբ", "Կիր"],
daysMin: ["Կի", "Եկ", "Եք", "Չո", "Հի", "Ու", "Շա", "Կի"],
months: ["Հունվար", "Փետրվար", "Մարտ", "Ապրիլ", "Մայիս", "Հունիս", "Հուլիս", "Օգոստոս", "Սեպտեմբեր", "Հոկտեմբեր", "Նոյեմբեր", "Դեկտեմբեր"],
monthsShort: ["Հնվ", "Փետ", "Մար", "Ապր", "Մայ", "Հուն", "Հուլ", "Օգս", "Սեպ", "Հոկ", "Նոյ", "Դեկ"],
today: "Այսօր",
suffix: [],
meridiem: []
};
}(jQuery));

View File

@@ -0,0 +1,19 @@
/**
* Bahasa translation for bootstrap-datetimepicker
* Azwar Akbar <azwar.akbar@gmail.com>
* Addtional by Yulian Sutopo <yuliansutopo@gmail.com>
*/
;(function($){
$.fn.datetimepicker.dates['id'] = {
days: ["Minggu", "Senin", "Selasa", "Rabu", "Kamis", "Jumat", "Sabtu", "Minggu"],
daysShort: ["Mng", "Sen", "Sel", "Rab", "Kam", "Jum", "Sab", "Mng"],
daysMin: ["Mg", "Sn", "Sl", "Ra", "Ka", "Ju", "Sa", "Mg"],
months: ["Januari", "Februari", "Maret", "April", "Mei", "Juni", "Juli", "Agustus", "September", "Oktober", "November", "Desember"],
monthsShort: ["Jan", "Feb", "Mar", "Apr", "Mei", "Jun", "Jul", "Ags", "Sep", "Okt", "Nov", "Des"],
today: "Hari Ini",
suffix: [],
meridiem: [],
weekStart: 1,
format: "dd/mm/yyyy hh:ii:ss"
};
}(jQuery));

View File

@@ -0,0 +1,16 @@
/**
* Icelandic translation for bootstrap-datetimepicker
* Hinrik Örn Sigurðsson <hinrik.sig@gmail.com>
*/
;(function($){
$.fn.datetimepicker.dates['is'] = {
days: ["Sunnudagur", "Mánudagur", "Þriðjudagur", "Miðvikudagur", "Fimmtudagur", "Föstudagur", "Laugardagur", "Sunnudagur"],
daysShort: ["Sun", "Mán", "Þri", "Mið", "Fim", "Fös", "Lau", "Sun"],
daysMin: ["Su", "Má", "Þr", "Mi", "Fi", "Fö", "La", "Su"],
months: ["Janúar", "Febrúar", "Mars", "Apríl", "Maí", "Júní", "Júlí", "Ágúst", "September", "Október", "Nóvember", "Desember"],
monthsShort: ["Jan", "Feb", "Mar", "Apr", "Maí", "Jún", "Júl", "Ágú", "Sep", "Okt", "Nóv", "Des"],
today: "Í Dag",
suffix: [],
meridiem: []
};
}(jQuery));

View File

@@ -0,0 +1,18 @@
/**
* Italian translation for bootstrap-datetimepicker
* Enrico Rubboli <rubboli@gmail.com>
*/
;(function($){
$.fn.datetimepicker.dates['it'] = {
days: ["Domenica", "Lunedi", "Martedi", "Mercoledi", "Giovedi", "Venerdi", "Sabato", "Domenica"],
daysShort: ["Dom", "Lun", "Mar", "Mer", "Gio", "Ven", "Sab", "Dom"],
daysMin: ["Do", "Lu", "Ma", "Me", "Gi", "Ve", "Sa", "Do"],
months: ["Gennaio", "Febbraio", "Marzo", "Aprile", "Maggio", "Giugno", "Luglio", "Agosto", "Settembre", "Ottobre", "Novembre", "Dicembre"],
monthsShort: ["Gen", "Feb", "Mar", "Apr", "Mag", "Giu", "Lug", "Ago", "Set", "Ott", "Nov", "Dic"],
today: "Oggi",
suffix: [],
meridiem: [],
weekStart: 1,
format: "dd/mm/yyyy hh:ii:ss"
};
}(jQuery));

View File

@@ -0,0 +1,16 @@
/**
* Japanese translation for bootstrap-datetimepicker
* Norio Suzuki <https://github.com/suzuki/>
*/
;(function($){
$.fn.datetimepicker.dates['ja'] = {
days: ["日曜", "月曜", "火曜", "水曜", "木曜", "金曜", "土曜", "日曜"],
daysShort: ["日", "月", "火", "水", "木", "金", "土", "日"],
daysMin: ["日", "月", "火", "水", "木", "金", "土", "日"],
months: ["1月", "2月", "3月", "4月", "5月", "6月", "7月", "8月", "9月", "10月", "11月", "12月"],
monthsShort: ["1月", "2月", "3月", "4月", "5月", "6月", "7月", "8月", "9月", "10月", "11月", "12月"],
today: "今日",
suffix: [],
meridiem: []
};
}(jQuery));

View File

@@ -0,0 +1,16 @@
/**
* Georgian translation for bootstrap-datetimepicker
* Zura Jijavadze <mailzura@gmail.com>
*/
;(function($){
$.fn.datetimepicker.dates['ka'] = {
days: ["კვირა", "ორშაბათი", "სამშაბათი", "ოთხშაბათი", "ხუთშაბათი", "პარასკევი", "შაბათი", "კვირა"],
daysShort: ["კვი", "ორშ", "სამ", "ოთხ", "ხუთ", "პარ", "შაბ", "კვი"],
daysMin: ["კვ", "ორ", "სა", "ოთ", "ხუ", "პა", "შა", "კვ"],
months: ["იანვარი", "თებერვალი", "მარტი", "აპრილი", "მაისი", "ივნისი", "ივლისი", "აგვისტო", "სექტემბერი", "ოქტომბერი", "ნოემბერი", "დეკემბერი"],
monthsShort: ["იან", "თებ", "მარ", "აპრ", "მაი", "ივნ", "ივლ", "აგვ", "სექ", "ოქტ", "ნოე", "დეკ"],
today: "დღეს",
suffix: [],
meridiem: []
};
}(jQuery));

View File

@@ -0,0 +1,17 @@
/**
* Korean translation for bootstrap-datetimepicker
* Gu Youn <http://github.com/guyoun>
* Baekjoon Choi <http://github.com/Baekjoon>
*/
;(function($){
$.fn.datetimepicker.dates['ko'] = {
days: ["일요일", "월요일", "화요일", "수요일", "목요일", "금요일", "토요일", "일요일"],
daysShort: ["일", "월", "화", "수", "목", "금", "토", "일"],
daysMin: ["일", "월", "화", "수", "목", "금", "토", "일"],
months: ["1월", "2월", "3월", "4월", "5월", "6월", "7월", "8월", "9월", "10월", "11월", "12월"],
monthsShort: ["1월", "2월", "3월", "4월", "5월", "6월", "7월", "8월", "9월", "10월", "11월", "12월"],
suffix: [],
meridiem: ["오전", "오후"],
today: "오늘",
};
}(jQuery));

View File

@@ -0,0 +1,18 @@
/**
* Lithuanian translation for bootstrap-datetimepicker
* Šarūnas Gliebus <ssharunas@yahoo.co.uk>
*/
;(function($){
$.fn.datetimepicker.dates['lt'] = {
days: ["Sekmadienis", "Pirmadienis", "Antradienis", "Trečiadienis", "Ketvirtadienis", "Penktadienis", "Šeštadienis", "Sekmadienis"],
daysShort: ["S", "Pr", "A", "T", "K", "Pn", "Š", "S"],
daysMin: ["Sk", "Pr", "An", "Tr", "Ke", "Pn", "Št", "Sk"],
months: ["Sausis", "Vasaris", "Kovas", "Balandis", "Gegužė", "Birželis", "Liepa", "Rugpjūtis", "Rugsėjis", "Spalis", "Lapkritis", "Gruodis"],
monthsShort: ["Sau", "Vas", "Kov", "Bal", "Geg", "Bir", "Lie", "Rugp", "Rugs", "Spa", "Lap", "Gru"],
today: "Šiandien",
suffix: [],
meridiem: [],
weekStart: 1
};
}(jQuery));

View File

@@ -0,0 +1,18 @@
/**
* Latvian translation for bootstrap-datetimepicker
* Artis Avotins <artis@apit.lv>
*/
;(function($){
$.fn.datetimepicker.dates['lv'] = {
days: ["Svētdiena", "Pirmdiena", "Otrdiena", "Trešdiena", "Ceturtdiena", "Piektdiena", "Sestdiena", "Svētdiena"],
daysShort: ["Sv", "P", "O", "T", "C", "Pk", "S", "Sv"],
daysMin: ["Sv", "Pr", "Ot", "Tr", "Ce", "Pk", "St", "Sv"],
months: ["Janvāris", "Februāris", "Marts", "Aprīlis", "Maijs", "Jūnijs", "Jūlijs", "Augusts", "Septembris", "Oktobris", "Novembris", "Decembris"],
monthsShort: ["Jan", "Feb", "Mar", "Apr", "Mai", "Jūn", "Jūl", "Aug", "Sep", "Okt", "Nov", "Dec."],
today: "Šodien",
suffix: [],
meridiem: [],
weekStart: 1
};
}(jQuery));

View File

@@ -0,0 +1,16 @@
/**
* Malay translation for bootstrap-datetimepicker
* Ateman Faiz <noorulfaiz@gmail.com>
*/
;(function($){
$.fn.datetimepicker.dates['ms'] = {
days: ["Ahad", "Isnin", "Selasa", "Rabu", "Khamis", "Jumaat", "Sabtu", "Ahad"],
daysShort: ["Aha", "Isn", "Sel", "Rab", "Kha", "Jum", "Sab", "Aha"],
daysMin: ["Ah", "Is", "Se", "Ra", "Kh", "Ju", "Sa", "Ah"],
months: ["Januari", "Februari", "Mac", "April", "Mei", "Jun", "Julai", "Ogos", "September", "Oktober", "November", "Disember"],
monthsShort: ["Jan", "Feb", "Mar", "Apr", "Mei", "Jun", "Jul", "Ogo", "Sep", "Okt", "Nov", "Dis"],
today: "Hari Ini",
suffix: [],
meridiem: []
};
}(jQuery));

View File

@@ -0,0 +1,16 @@
/**
* Norwegian (bokmål) translation for bootstrap-datetimepicker
* Fredrik Sundmyhr <http://github.com/fsundmyhr>
*/
;(function($){
$.fn.datetimepicker.dates['nb'] = {
days: ["Søndag", "Mandag", "Tirsdag", "Onsdag", "Torsdag", "Fredag", "Lørdag", "Søndag"],
daysShort: ["Søn", "Man", "Tir", "Ons", "Tor", "Fre", "Lør", "Søn"],
daysMin: ["Sø", "Ma", "Ti", "On", "To", "Fr", "Lø", "Sø"],
months: ["Januar", "Februar", "Mars", "April", "Mai", "Juni", "Juli", "August", "September", "Oktober", "November", "Desember"],
monthsShort: ["Jan", "Feb", "Mar", "Apr", "Mai", "Jun", "Jul", "Aug", "Sep", "Okt", "Nov", "Des"],
today: "I Dag",
suffix: [],
meridiem: []
};
}(jQuery));

View File

@@ -0,0 +1,16 @@
/**
* Dutch translation for bootstrap-datetimepicker
* Reinier Goltstein <mrgoltstein@gmail.com>
*/
;(function($){
$.fn.datetimepicker.dates['nl'] = {
days: ["Zondag", "Maandag", "Dinsdag", "Woensdag", "Donderdag", "Vrijdag", "Zaterdag", "Zondag"],
daysShort: ["Zo", "Ma", "Di", "Wo", "Do", "Vr", "Za", "Zo"],
daysMin: ["Zo", "Ma", "Di", "Wo", "Do", "Vr", "Za", "Zo"],
months: ["Januari", "Februari", "Maart", "April", "Mei", "Juni", "Juli", "Augustus", "September", "Oktober", "November", "December"],
monthsShort: ["Jan", "Feb", "Mrt", "Apr", "Mei", "Jun", "Jul", "Aug", "Sep", "Okt", "Nov", "Dec"],
today: "Vandaag",
suffix: [],
meridiem: []
};
}(jQuery));

View File

@@ -0,0 +1,16 @@
/**
* Norwegian translation for bootstrap-datetimepicker
* Rune Warhuus <rune@dinkdonkd.no>
*/
;(function($){
$.fn.datetimepicker.dates['no'] = {
days: ["Søndag", "Mandag", "Tirsdag", "Onsdag", "Torsdag", "Fredag", "Lørdag", "Søndag"],
daysShort: ["Søn", "Man", "Tir", "Ons", "Tor", "Fre", "Lør", "Søn"],
daysMin: ["Sø", "Ma", "Ti", "On", "To", "Fr", "Lø", "Sø"],
months: ["Januar", "Februar", "Mars", "April", "Mai", "Juni", "Juli", "August", "September", "Oktober", "November", "Desember"],
monthsShort: ["Jan", "Feb", "Mar", "Apr", "Mai", "Jun", "Jul", "Aug", "Sep", "Okt", "Nov", "Des"],
today: "I Dag",
suffix: [],
meridiem: []
};
}(jQuery));

View File

@@ -0,0 +1,17 @@
/**
* Polish translation for bootstrap-datetimepicker
* Robert <rtpm@gazeta.pl>
*/
;(function($){
$.fn.datetimepicker.dates['pl'] = {
days: ["Niedziela", "Poniedziałek", "Wtorek", "Środa", "Czwartek", "Piątek", "Sobota", "Niedziela"],
daysShort: ["Nie", "Pn", "Wt", "Śr", "Czw", "Pt", "So", "Nie"],
daysMin: ["N", "Pn", "Wt", "Śr", "Cz", "Pt", "So", "N"],
months: ["Styczeń", "Luty", "Marzec", "Kwiecień", "Maj", "Czerwiec", "Lipiec", "Sierpień", "Wrzesień", "Październik", "Listopad", "Grudzień"],
monthsShort: ["Sty", "Lu", "Mar", "Kw", "Maj", "Cze", "Lip", "Sie", "Wrz", "Pa", "Lis", "Gru"],
today: "Dzisiaj",
suffix: [],
meridiem: [],
weekStart: 1
};
}(jQuery));

View File

@@ -0,0 +1,17 @@
/**
* Brazilian translation for bootstrap-datetimepicker
* Cauan Cabral <cauan@radig.com.br>
*/
;(function($){
$.fn.datetimepicker.dates['pt-BR'] = {
format: 'dd/mm/yyyy',
days: ["Domingo", "Segunda", "Terça", "Quarta", "Quinta", "Sexta", "Sábado", "Domingo"],
daysShort: ["Dom", "Seg", "Ter", "Qua", "Qui", "Sex", "Sáb", "Dom"],
daysMin: ["Do", "Se", "Te", "Qu", "Qu", "Se", "Sa", "Do"],
months: ["Janeiro", "Fevereiro", "Março", "Abril", "Maio", "Junho", "Julho", "Agosto", "Setembro", "Outubro", "Novembro", "Dezembro"],
monthsShort: ["Jan", "Fev", "Mar", "Abr", "Mai", "Jun", "Jul", "Ago", "Set", "Out", "Nov", "Dez"],
today: "Hoje",
suffix: [],
meridiem: []
};
}(jQuery));

View File

@@ -0,0 +1,17 @@
/**
* Portuguese translation for bootstrap-datetimepicker
* Original code: Cauan Cabral <cauan@radig.com.br>
* Tiago Melo <tiago.blackcode@gmail.com>
*/
;(function($){
$.fn.datetimepicker.dates['pt'] = {
days: ["Domingo", "Segunda", "Terça", "Quarta", "Quinta", "Sexta", "Sábado", "Domingo"],
daysShort: ["Dom", "Seg", "Ter", "Qua", "Qui", "Sex", "Sáb", "Dom"],
daysMin: ["Do", "Se", "Te", "Qu", "Qu", "Se", "Sa", "Do"],
months: ["Janeiro", "Fevereiro", "Março", "Abril", "Maio", "Junho", "Julho", "Agosto", "Setembro", "Outubro", "Novembro", "Dezembro"],
monthsShort: ["Jan", "Fev", "Mar", "Abr", "Mai", "Jun", "Jul", "Ago", "Set", "Out", "Nov", "Dez"],
suffix: [],
meridiem: [],
today: "Hoje"
};
}(jQuery));

View File

@@ -0,0 +1,17 @@
/**
* Romanian translation for bootstrap-datetimepicker
* Cristian Vasile <cristi.mie@gmail.com>
*/
;(function($){
$.fn.datetimepicker.dates['ro'] = {
days: ["Duminică", "Luni", "Marţi", "Miercuri", "Joi", "Vineri", "Sâmbătă", "Duminică"],
daysShort: ["Dum", "Lun", "Mar", "Mie", "Joi", "Vin", "Sâm", "Dum"],
daysMin: ["Du", "Lu", "Ma", "Mi", "Jo", "Vi", "Sâ", "Du"],
months: ["Ianuarie", "Februarie", "Martie", "Aprilie", "Mai", "Iunie", "Iulie", "August", "Septembrie", "Octombrie", "Noiembrie", "Decembrie"],
monthsShort: ["Ian", "Feb", "Mar", "Apr", "Mai", "Iun", "Iul", "Aug", "Sep", "Oct", "Nov", "Dec"],
today: "Astăzi",
suffix: [],
meridiem: [],
weekStart: 1
};
}(jQuery));

View File

@@ -0,0 +1,16 @@
/**
* Serbian latin translation for bootstrap-datetimepicker
* Bojan Milosavlević <milboj@gmail.com>
*/
;(function($){
$.fn.datetimepicker.dates['rs'] = {
days: ["Nedelja","Ponedeljak", "Utorak", "Sreda", "Četvrtak", "Petak", "Subota", "Nedelja"],
daysShort: ["Ned", "Pon", "Uto", "Sre", "Čet", "Pet", "Sub", "Ned"],
daysMin: ["N", "Po", "U", "Sr", "Č", "Pe", "Su", "N"],
months: ["Januar", "Februar", "Mart", "April", "Maj", "Jun", "Jul", "Avgust", "Septembar", "Oktobar", "Novembar", "Decembar"],
monthsShort: ["Jan", "Feb", "Mar", "Apr", "Maj", "Jun", "Jul", "Avg", "Sep", "Okt", "Nov", "Dec"],
today: "Danas",
suffix: [],
meridiem: []
};
}(jQuery));

View File

@@ -0,0 +1,16 @@
/**
* Serbian cyrillic translation for bootstrap-datetimepicker
* Bojan Milosavlević <milboj@gmail.com>
*/
;(function($){
$.fn.datetimepicker.dates['rs'] = {
days: ["Недеља","Понедељак", "Уторак", "Среда", "Четвртак", "Петак", "Субота", "Недеља"],
daysShort: ["Нед", "Пон", "Уто", "Сре", "Чет", "Пет", "Суб", "Нед"],
daysMin: ["Н", "По", "У", "Ср", "Ч", "Пе", "Су", "Н"],
months: ["Јануар", "Фебруар", "Март", "Април", "Мај", "Јун", "Јул", "Август", "Септембар", "Октобар", "Новембар", "Децембар"],
monthsShort: ["Јан", "Феб", "Мар", "Апр", "Мај", "Јун", "Јул", "Авг", "Сеп", "Окт", "Нов", "Дец"],
today: "Данас",
suffix: [],
meridiem: []
};
}(jQuery));

View File

@@ -0,0 +1,16 @@
/**
* Russian translation for bootstrap-datetimepicker
* Victor Taranenko <darwin@snowdale.com>
*/
;(function($){
$.fn.datetimepicker.dates['ru'] = {
days: ["Воскресенье", "Понедельник", "Вторник", "Среда", "Четверг", "Пятница", "Суббота", "Воскресенье"],
daysShort: ["Вск", "Пнд", "Втр", "Срд", "Чтв", "Птн", "Суб", "Вск"],
daysMin: ["Вс", "Пн", "Вт", "Ср", "Чт", "Пт", "Сб", "Вс"],
months: ["Январь", "Февраль", "Март", "Апрель", "Май", "Июнь", "Июль", "Август", "Сентябрь", "Октябрь", "Ноябрь", "Декабрь"],
monthsShort: ["Янв", "Фев", "Мар", "Апр", "Май", "Июн", "Июл", "Авг", "Сен", "Окт", "Ноя", "Дек"],
today: "Сегодня",
suffix: [],
meridiem: []
};
}(jQuery));

View File

@@ -0,0 +1,19 @@
/**
* Slovak translation for bootstrap-datetimepicker
* Marek Lichtner <marek@licht.sk>
* Fixes by Michal Remiš <michal.remis@gmail.com>
*/
;(function($){
$.fn.datetimepicker.dates["sk"] = {
days: ["Nedeľa", "Pondelok", "Utorok", "Streda", "Štvrtok", "Piatok", "Sobota", "Nedeľa"],
daysShort: ["Ned", "Pon", "Uto", "Str", "Štv", "Pia", "Sob", "Ned"],
daysMin: ["Ne", "Po", "Ut", "St", "Št", "Pi", "So", "Ne"],
months: ["Január", "Február", "Marec", "Apríl", "Máj", "Jún", "Júl", "August", "September", "Október", "November", "December"],
monthsShort: ["Jan", "Feb", "Mar", "Apr", "Máj", "Jún", "Júl", "Aug", "Sep", "Okt", "Nov", "Dec"],
today: "Dnes",
suffix: [],
meridiem: [],
weekStart: 1,
format: "dd.mm.yyyy"
};
}(jQuery));

View File

@@ -0,0 +1,16 @@
/**
* Slovene translation for bootstrap-datetimepicker
* Gregor Rudolf <gregor.rudolf@gmail.com>
*/
;(function($){
$.fn.datetimepicker.dates['sl'] = {
days: ["Nedelja", "Ponedeljek", "Torek", "Sreda", "Četrtek", "Petek", "Sobota", "Nedelja"],
daysShort: ["Ned", "Pon", "Tor", "Sre", "Čet", "Pet", "Sob", "Ned"],
daysMin: ["Ne", "Po", "To", "Sr", "Če", "Pe", "So", "Ne"],
months: ["Januar", "Februar", "Marec", "April", "Maj", "Junij", "Julij", "Avgust", "September", "Oktober", "November", "December"],
monthsShort: ["Jan", "Feb", "Mar", "Apr", "Maj", "Jun", "Jul", "Avg", "Sep", "Okt", "Nov", "Dec"],
today: "Danes",
suffix: [],
meridiem: []
};
}(jQuery));

View File

@@ -0,0 +1,16 @@
/**
* Swedish translation for bootstrap-datetimepicker
* Patrik Ragnarsson <patrik@starkast.net>
*/
;(function($){
$.fn.datetimepicker.dates['sv'] = {
days: ["Söndag", "Måndag", "Tisdag", "Onsdag", "Torsdag", "Fredag", "Lördag", "Söndag"],
daysShort: ["Sön", "Mån", "Tis", "Ons", "Tor", "Fre", "Lör", "Sön"],
daysMin: ["Sö", "Må", "Ti", "On", "To", "Fr", "Lö", "Sö"],
months: ["Januari", "Februari", "Mars", "April", "Maj", "Juni", "Juli", "Augusti", "September", "Oktober", "November", "December"],
monthsShort: ["Jan", "Feb", "Mar", "Apr", "Maj", "Jun", "Jul", "Aug", "Sep", "Okt", "Nov", "Dec"],
today: "I Dag",
suffix: [],
meridiem: []
};
}(jQuery));

View File

@@ -0,0 +1,17 @@
/**
* Swahili translation for bootstrap-datetimepicker
* Edwin Mugendi <https://github.com/edwinmugendi>
* Source: http://scriptsource.org/cms/scripts/page.php?item_id=entry_detail&uid=xnfaqyzcku
*/
;(function($){
$.fn.datetimepicker.dates['sw'] = {
days: ["Jumapili", "Jumatatu", "Jumanne", "Jumatano", "Alhamisi", "Ijumaa", "Jumamosi", "Jumapili"],
daysShort: ["J2", "J3", "J4", "J5", "Alh", "Ij", "J1", "J2"],
daysMin: ["2", "3", "4", "5", "A", "I", "1", "2"],
months: ["Januari", "Februari", "Machi", "Aprili", "Mei", "Juni", "Julai", "Agosti", "Septemba", "Oktoba", "Novemba", "Desemba"],
monthsShort: ["Jan", "Feb", "Mac", "Apr", "Mei", "Jun", "Jul", "Ago", "Sep", "Okt", "Nov", "Des"],
today: "Leo",
suffix: [],
meridiem: []
};
}(jQuery));

View File

@@ -0,0 +1,16 @@
/**
* Thai translation for bootstrap-datetimepicker
* Suchau Jiraprapot <seroz24@gmail.com>
*/
;(function($){
$.fn.datetimepicker.dates['th'] = {
days: ["อาทิตย์", "จันทร์", "อังคาร", "พุธ", "พฤหัส", "ศุกร์", "เสาร์", "อาทิตย์"],
daysShort: ["อา", "จ", "อ", "พ", "พฤ", "ศ", "ส", "อา"],
daysMin: ["อา", "จ", "อ", "พ", "พฤ", "ศ", "ส", "อา"],
months: ["มกราคม", "กุมภาพันธ์", "มีนาคม", "เมษายน", "พฤษภาคม", "มิถุนายน", "กรกฎาคม", "สิงหาคม", "กันยายน", "ตุลาคม", "พฤศจิกายน", "ธันวาคม"],
monthsShort: ["ม.ค.", "ก.พ.", "มี.ค.", "เม.ย.", "พ.ค.", "มิ.ย.", "ก.ค.", "ส.ค.", "ก.ย.", "ต.ค.", "พ.ย.", "ธ.ค."],
today: "วันนี้",
suffix: [],
meridiem: []
};
}(jQuery));

View File

@@ -0,0 +1,17 @@
/**
* Turkish translation for bootstrap-datetimepicker
* Serkan Algur <kaisercrazy_2@hotmail.com>
*/
;(function($){
$.fn.datetimepicker.dates['tr'] = {
days: ["Pazar", "Pazartesi", "Salı", "Çarşamba", "Perşembe", "Cuma", "Cumartesi", "Pazar"],
daysShort: ["Pz", "Pzt", "Sal", "Çrş", "Prş", "Cu", "Cts", "Pz"],
daysMin: ["Pz", "Pzt", "Sa", "Çr", "Pr", "Cu", "Ct", "Pz"],
months: ["Ocak", "Şubat", "Mart", "Nisan", "Mayıs", "Haziran", "Temmuz", "Ağustos", "Eylül", "Ekim", "Kasım", "Aralık"],
monthsShort: ["Oca", "Şub", "Mar", "Nis", "May", "Haz", "Tem", "Ağu", "Eyl", "Eki", "Kas", "Ara"],
today: "Bugün",
suffix: [],
meridiem: []
};
}(jQuery));

View File

@@ -0,0 +1,15 @@
/**
* Ukrainian translation for bootstrap-datepicker
* Igor Polynets
*/
;(function($){
$.fn.datetimepicker.dates['ua'] = {
days: ["Неділя", "Понеділок", "Вівторок", "Середа", "Четверг", "П'ятниця", "Субота", "Неділя"],
daysShort: ["Нед", "Пнд", "Втр", "Срд", "Чтв", "Птн", "Суб", "Нед"],
daysMin: ["Нд", "Пн", "Вт", "Ср", "Чт", "Пт", "Сб", "Нд"],
months: ["Cічень", "Лютий", "Березень", "Квітень", "Травень", "Червень", "Липень", "Серпень", "Вересень", "Жовтень", "Листопад", "Грудень"],
monthsShort: ["Січ", "Лют", "Бер", "Квт", "Трв", "Чер", "Лип", "Сер", "Вер", "Жов", "Лис", "Грд"],
today: "Сьогодні",
weekStart: 1
};
}(jQuery));

View File

@@ -0,0 +1,16 @@
/**
* Ukrainian translation for bootstrap-datetimepicker
* Andrey Vityuk <andrey [dot] vityuk [at] gmail.com>
*/
;(function($){
$.fn.datetimepicker.dates['uk'] = {
days: ["Неділя", "Понеділок", "Вівторок", "Середа", "Четвер", "П'ятниця", "Субота", "Неділя"],
daysShort: ["Нед", "Пнд", "Втр", "Срд", "Чтв", "Птн", "Суб", "Нед"],
daysMin: ["Нд", "Пн", "Вт", "Ср", "Чт", "Пт", "Сб", "Нд"],
months: ["Січень", "Лютий", "Березень", "Квітень", "Травень", "Червень", "Липень", "Серпень", "Вересень", "Жовтень", "Листопад", "Грудень"],
monthsShort: ["Січ", "Лют", "Бер", "Кві", "Тра", "Чер", "Лип", "Сер", "Вер", "Жов", "Лис", "Гру"],
today: "Сьогодні",
suffix: [],
meridiem: []
};
}(jQuery));

View File

@@ -0,0 +1,16 @@
/**
* Simplified Chinese translation for bootstrap-datetimepicker
* Yuan Cheung <advanimal@gmail.com>
*/
;(function($){
$.fn.datetimepicker.dates['zh-CN'] = {
days: ["星期日", "星期一", "星期二", "星期三", "星期四", "星期五", "星期六", "星期日"],
daysShort: ["周日", "周一", "周二", "周三", "周四", "周五", "周六", "周日"],
daysMin: ["日", "一", "二", "三", "四", "五", "六", "日"],
months: ["一月", "二月", "三月", "四月", "五月", "六月", "七月", "八月", "九月", "十月", "十一月", "十二月"],
monthsShort: ["一月", "二月", "三月", "四月", "五月", "六月", "七月", "八月", "九月", "十月", "十一月", "十二月"],
today: "今天",
suffix: [],
meridiem: ["上午", "下午"]
};
}(jQuery));

View File

@@ -0,0 +1,16 @@
/**
* Traditional Chinese translation for bootstrap-datetimepicker
* Rung-Sheng Jang <daniel@i-trend.co.cc>
*/
;(function($){
$.fn.datetimepicker.dates['zh-TW'] = {
days: ["星期日", "星期一", "星期二", "星期三", "星期四", "星期五", "星期六", "星期日"],
daysShort: ["周日", "周一", "周二", "周三", "周四", "周五", "周六", "周日"],
daysMin: ["日", "一", "二", "三", "四", "五", "六", "日"],
months: ["一月", "二月", "三月", "四月", "五月", "六月", "七月", "八月", "九月", "十月", "十一月", "十二月"],
monthsShort: ["一月", "二月", "三月", "四月", "五月", "六月", "七月", "八月", "九月", "十月", "十一月", "十二月"],
today: "今天",
suffix: [],
meridiem: ["上午", "下午"]
};
}(jQuery));

View File

@@ -0,0 +1,418 @@
/*!
* Datetimepicker for Bootstrap
*
* Copyright 2012 Stefan Petre
* Improvements by Andrew Rowls
* Improvements by Sébastien Malot
* Licensed under the Apache License v2.0
* http://www.apache.org/licenses/LICENSE-2.0
*
*/
.datetimepicker {
padding: 4px;
margin-top: 1px;
white-space: normal;
-webkit-border-radius: 4px;
-moz-border-radius: 4px;
border-radius: 4px;
direction: ltr;
&.datetimepicker-rtl {
direction: rtl;
table {
tr {
td {
span {
float: right;
}
}
}
}
}
& > div {
display: none;
}
&.minutes {
div {
&.datetimepicker-minutes {
display: block;
}
}
}
&.hours {
div {
&.datetimepicker-hours {
display: block;
}
}
}
&.days {
div {
&.datetimepicker-days {
display: block;
}
}
}
&.months {
div {
&.datetimepicker-months {
display: block;
}
}
}
&.years {
div {
&.datetimepicker-years {
display: block;
}
}
}
table {
margin: 0;
tr {
td {
&.minute {
&:hover {
background: #eeeeee;
cursor: pointer;
}
}
&.hour {
&:hover {
background: #eeeeee;
cursor: pointer;
}
}
&.day {
&:hover {
background: #eeeeee;
cursor: pointer;
}
}
span {
display: block;
width: 23%;
height: 54px;
line-height: 54px;
float: left;
margin: 1%;
cursor: pointer;
-webkit-border-radius: 4px;
-moz-border-radius: 4px;
border-radius: 4px;
&:hover {
background: #eeeeee;
}
&.old {
color: #999999;
}
}
}
}
}
.datetimepicker-hours {
span {
height: 26px;
line-height: 26px;
}
}
.datetimepicker-minutes {
span {
height: 26px;
line-height: 26px;
}
}
th {
&.switch {
width: 145px;
}
}
}
.datetimepicker-inline {
width: 220px;
}
.datetimepicker-dropdown, .datetimepicker-dropdown-left {
top: 0;
left: 0;
}
[class*="datetimepicker-dropdown"]:before {
content: '';
display: inline-block;
border-left: 7px solid transparent;
border-right: 7px solid transparent;
border-bottom: 7px solid #ccc;
border-bottom-color: rgba(0, 0, 0, 0.2);
position: absolute;
}
[class*="datetimepicker-dropdown"]:after {
content: '';
display: inline-block;
border-left: 6px solid transparent;
border-right: 6px solid transparent;
border-bottom: 6px solid #ffffff;
position: absolute;
}
[class*="datetimepicker-dropdown-top"]:before {
content: '';
display: inline-block;
border-left: 7px solid transparent;
border-right: 7px solid transparent;
border-top: 7px solid #ccc;
border-top-color: rgba(0, 0, 0, 0.2);
border-bottom: 0;
}
[class*="datetimepicker-dropdown-top"]:after {
content: '';
display: inline-block;
border-left: 6px solid transparent;
border-right: 6px solid transparent;
border-top: 6px solid #ffffff;
border-bottom: 0;
}
.datetimepicker-dropdown-bottom-left {
&:before {
top: -7px;
right: 6px;
}
&:after {
top: -6px;
right: 7px;
}
}
.datetimepicker-dropdown-bottom-right {
&:before {
top: -7px;
left: 6px;
}
&:after {
top: -6px;
left: 7px;
}
}
.datetimepicker-dropdown-top-left {
&:before {
bottom: -7px;
right: 6px;
}
&:after {
bottom: -6px;
right: 7px;
}
}
.datetimepicker-dropdown-top-right {
&:before {
bottom: -7px;
left: 6px;
}
&:after {
bottom: -6px;
left: 7px;
}
}
.datetimepicker td,
.datetimepicker th {
text-align: center;
width: 20px;
height: 20px;
-webkit-border-radius: 4px;
-moz-border-radius: 4px;
border-radius: 4px;
border: none;
}
.table-striped .datetimepicker table tr td,
.table-striped .datetimepicker table tr th {
background-color: transparent;
}
.datetimepicker table tr td.old,
.datetimepicker table tr td.new {
color: #999999;
}
.datetimepicker table tr td.disabled,
.datetimepicker table tr td.disabled:hover {
background: none;
color: #999999;
cursor: default;
}
.datetimepicker table tr td.today,
.datetimepicker table tr td.today:hover,
.datetimepicker table tr td.today.disabled,
.datetimepicker table tr td.today.disabled:hover {
background-color: #fde19a;
background-image: -moz-linear-gradient(top, #fdd49a, #fdf59a);
background-image: -ms-linear-gradient(top, #fdd49a, #fdf59a);
background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#fdd49a), to(#fdf59a));
background-image: -webkit-linear-gradient(top, #fdd49a, #fdf59a);
background-image: -o-linear-gradient(top, #fdd49a, #fdf59a);
background-image: linear-gradient(to bottom, #fdd49a, #fdf59a);
background-repeat: repeat-x;
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#fdd49a', endColorstr='#fdf59a', GradientType=0);
border-color: #fdf59a #fdf59a #fbed50;
border-color: rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.25);
filter: progid:DXImageTransform.Microsoft.gradient(enabled=false);
}
.datetimepicker table tr td.today:hover,
.datetimepicker table tr td.today:hover:hover,
.datetimepicker table tr td.today.disabled:hover,
.datetimepicker table tr td.today.disabled:hover:hover,
.datetimepicker table tr td.today:active,
.datetimepicker table tr td.today:hover:active,
.datetimepicker table tr td.today.disabled:active,
.datetimepicker table tr td.today.disabled:hover:active,
.datetimepicker table tr td.today.active,
.datetimepicker table tr td.today:hover.active,
.datetimepicker table tr td.today.disabled.active,
.datetimepicker table tr td.today.disabled:hover.active,
.datetimepicker table tr td.today.disabled,
.datetimepicker table tr td.today:hover.disabled,
.datetimepicker table tr td.today.disabled.disabled,
.datetimepicker table tr td.today.disabled:hover.disabled,
.datetimepicker table tr td.today[disabled],
.datetimepicker table tr td.today:hover[disabled],
.datetimepicker table tr td.today.disabled[disabled],
.datetimepicker table tr td.today.disabled:hover[disabled] {
background-color: #fdf59a;
}
.datetimepicker table tr td.today:active,
.datetimepicker table tr td.today:hover:active,
.datetimepicker table tr td.today.disabled:active,
.datetimepicker table tr td.today.disabled:hover:active,
.datetimepicker table tr td.today.active,
.datetimepicker table tr td.today:hover.active,
.datetimepicker table tr td.today.disabled.active,
.datetimepicker table tr td.today.disabled:hover.active {
background-color: #fbf069 \9;
}
.datetimepicker table tr td.active,
.datetimepicker table tr td.active:hover,
.datetimepicker table tr td.active.disabled,
.datetimepicker table tr td.active.disabled:hover {
background-color: #006dcc;
background-image: -moz-linear-gradient(top, #0088cc, #0044cc);
background-image: -ms-linear-gradient(top, #0088cc, #0044cc);
background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#0088cc), to(#0044cc));
background-image: -webkit-linear-gradient(top, #0088cc, #0044cc);
background-image: -o-linear-gradient(top, #0088cc, #0044cc);
background-image: linear-gradient(to bottom, #0088cc, #0044cc);
background-repeat: repeat-x;
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#0088cc', endColorstr='#0044cc', GradientType=0);
border-color: #0044cc #0044cc #002a80;
border-color: rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.25);
filter: progid:DXImageTransform.Microsoft.gradient(enabled=false);
color: #fff;
text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.25);
}
.datetimepicker table tr td.active:hover,
.datetimepicker table tr td.active:hover:hover,
.datetimepicker table tr td.active.disabled:hover,
.datetimepicker table tr td.active.disabled:hover:hover,
.datetimepicker table tr td.active:active,
.datetimepicker table tr td.active:hover:active,
.datetimepicker table tr td.active.disabled:active,
.datetimepicker table tr td.active.disabled:hover:active,
.datetimepicker table tr td.active.active,
.datetimepicker table tr td.active:hover.active,
.datetimepicker table tr td.active.disabled.active,
.datetimepicker table tr td.active.disabled:hover.active,
.datetimepicker table tr td.active.disabled,
.datetimepicker table tr td.active:hover.disabled,
.datetimepicker table tr td.active.disabled.disabled,
.datetimepicker table tr td.active.disabled:hover.disabled,
.datetimepicker table tr td.active[disabled],
.datetimepicker table tr td.active:hover[disabled],
.datetimepicker table tr td.active.disabled[disabled],
.datetimepicker table tr td.active.disabled:hover[disabled] {
background-color: #0044cc;
}
.datetimepicker table tr td.active:active,
.datetimepicker table tr td.active:hover:active,
.datetimepicker table tr td.active.disabled:active,
.datetimepicker table tr td.active.disabled:hover:active,
.datetimepicker table tr td.active.active,
.datetimepicker table tr td.active:hover.active,
.datetimepicker table tr td.active.disabled.active,
.datetimepicker table tr td.active.disabled:hover.active {
background-color: #003399 \9;
}
.datetimepicker .datetimepicker-hours table tr td span.hour_am,
.datetimepicker .datetimepicker-hours table tr td span.hour_pm {
width: 14.6%;
}
.datetimepicker .datetimepicker-hours fieldset legend,
.datetimepicker .datetimepicker-minutes fieldset legend {
margin-bottom: inherit;
line-height: 30px;
}
.datetimepicker table tr td span.disabled,
.datetimepicker table tr td span.disabled:hover {
background: none;
color: #999999;
cursor: default;
}
.datetimepicker table tr td span.active,
.datetimepicker table tr td span.active:hover,
.datetimepicker table tr td span.active.disabled,
.datetimepicker table tr td span.active.disabled:hover {
background-color: #006dcc;
background-image: -moz-linear-gradient(top, #0088cc, #0044cc);
background-image: -ms-linear-gradient(top, #0088cc, #0044cc);
background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#0088cc), to(#0044cc));
background-image: -webkit-linear-gradient(top, #0088cc, #0044cc);
background-image: -o-linear-gradient(top, #0088cc, #0044cc);
background-image: linear-gradient(to bottom, #0088cc, #0044cc);
background-repeat: repeat-x;
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#0088cc', endColorstr='#0044cc', GradientType=0);
border-color: #0044cc #0044cc #002a80;
border-color: rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.1) rgba(0, 0, 0, 0.25);
filter: progid:DXImageTransform.Microsoft.gradient(enabled=false);
color: #fff;
text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.25);
}
.datetimepicker table tr td span.active:hover,
.datetimepicker table tr td span.active:hover:hover,
.datetimepicker table tr td span.active.disabled:hover,
.datetimepicker table tr td span.active.disabled:hover:hover,
.datetimepicker table tr td span.active:active,
.datetimepicker table tr td span.active:hover:active,
.datetimepicker table tr td span.active.disabled:active,
.datetimepicker table tr td span.active.disabled:hover:active,
.datetimepicker table tr td span.active.active,
.datetimepicker table tr td span.active:hover.active,
.datetimepicker table tr td span.active.disabled.active,
.datetimepicker table tr td span.active.disabled:hover.active,
.datetimepicker table tr td span.active.disabled,
.datetimepicker table tr td span.active:hover.disabled,
.datetimepicker table tr td span.active.disabled.disabled,
.datetimepicker table tr td span.active.disabled:hover.disabled,
.datetimepicker table tr td span.active[disabled],
.datetimepicker table tr td span.active:hover[disabled],
.datetimepicker table tr td span.active.disabled[disabled],
.datetimepicker table tr td span.active.disabled:hover[disabled] {
background-color: #0044cc;
}
.datetimepicker table tr td span.active:active,
.datetimepicker table tr td span.active:hover:active,
.datetimepicker table tr td span.active.disabled:active,
.datetimepicker table tr td span.active.disabled:hover:active,
.datetimepicker table tr td span.active.active,
.datetimepicker table tr td span.active:hover.active,
.datetimepicker table tr td span.active.disabled.active,
.datetimepicker table tr td span.active.disabled:hover.active {
background-color: #003399 \9;
}
.datetimepicker thead tr:first-child th,
.datetimepicker tfoot tr:first-child th {
cursor: pointer;
}
.datetimepicker thead tr:first-child th:hover,
.datetimepicker tfoot tr:first-child th:hover {
background: #eeeeee;
}
.input-append.date .add-on i,
.input-prepend.date .add-on i,
.input-group.date .input-group-addon span {
cursor: pointer;
width: 14px;
height: 14px;
}

View File

@@ -0,0 +1,10 @@
#!/bin/sh
# You can download yuicompressor here https://github.com/yui/yuicompressor/releases/tag/v2.4.8
# Using WGET: $ wget https://github.com/yui/yuicompressor/releases/download/v2.4.8/yuicompressor-2.4.8.jar
#
# Put the JAR file into root of this project!
# Make this script executable and then run: ./minify.sh
java -jar yuicompressor-2.4.8.jar css/bootstrap-datetimepicker.css > css/bootstrap-datetimepicker.min.css
java -jar yuicompressor-2.4.8.jar js/bootstrap-datetimepicker.js > js/bootstrap-datetimepicker.min.js

View File

@@ -0,0 +1,35 @@
{
"name": "bootstrap-datetime-picker",
"homepage": "http://www.malot.fr/bootstrap-datetimepicker/",
"description": "Both Date and Time picker widget based on twitter bootstrap",
"version": "2.4.4",
"license": "Apache 2.0",
"author": {
"name": "Sebastien Malot"
},
"maintainers": [{
"name": "Sebastien Malot"
},{
"name": "Christian Vaas",
"email": "christianvaas@auspex.eu"
}
],
"keywords": [
"bootstrap", "datetime", "picker"
],
"repository": {
"type": "git",
"url": "git://github.com/smalot/bootstrap-datetimepicker.git"
},
"bugs": {
"url": "https://github.com/smalot/bootstrap-datetimepicker"
},
"main": "./js/bootstrap-datetimepicker.js",
"devDependencies": {
"grunt": "^1.0.1",
"grunt-contrib-jshint": "^1.0.0",
"grunt-version-check": "^0.3.7",
"jshint": "^2.9.4",
"load-grunt-tasks": "^3.4.1"
}
}

File diff suppressed because it is too large Load Diff

File diff suppressed because one or more lines are too long

Binary file not shown.

After

Width:  |  Height:  |  Size: 8.6 KiB

Some files were not shown because too many files have changed in this diff Show More