├── .bowerrc ├── .editorconfig ├── .gitattributes ├── .gitignore ├── .jshintrc ├── .project ├── .travis.yml ├── Gruntfile.coffee ├── Gruntfile.js ├── README.md ├── android ├── .classpath ├── .project ├── .settings │ └── org.eclipse.jdt.core.prefs ├── AndroidManifest.xml ├── bin │ ├── AndroidManifest.xml │ ├── Mifan.apk │ ├── classes.dex │ ├── classes │ │ ├── net │ │ │ └── thinkalways │ │ │ │ └── util │ │ │ │ ├── StreamTool.class │ │ │ │ ├── StringUtils.class │ │ │ │ └── UIHelper.class │ │ └── us │ │ │ └── mifan │ │ │ ├── BuildConfig.class │ │ │ ├── LoginActivity$LoginButtonClickListener$1.class │ │ │ ├── LoginActivity$LoginButtonClickListener$2.class │ │ │ ├── LoginActivity$LoginButtonClickListener.class │ │ │ ├── LoginActivity.class │ │ │ ├── R$attr.class │ │ │ ├── R$drawable.class │ │ │ ├── R$id.class │ │ │ ├── R$layout.class │ │ │ ├── R$string.class │ │ │ ├── R$style.class │ │ │ ├── R.class │ │ │ └── app │ │ │ ├── AppConfig.class │ │ │ ├── AppContext.class │ │ │ ├── AppException.class │ │ │ ├── AppManager.class │ │ │ ├── api │ │ │ └── ApiClient.class │ │ │ └── bean │ │ │ ├── Result.class │ │ │ └── URLs.class │ ├── dexedLibs │ │ ├── android-support-v4-ad00ea57bbaa4b8c1c88b9dff88a200c.jar │ │ └── commons-httpclient-3.1-fbe8919365b212e6ac94e77c9eecb585.jar │ ├── jarlist.cache │ ├── res │ │ └── crunch │ │ │ ├── drawable-hdpi │ │ │ └── ic_launcher.png │ │ │ ├── drawable-mdpi │ │ │ ├── blue_button.9.png │ │ │ └── ic_launcher.png │ │ │ └── drawable-xhdpi │ │ │ └── ic_launcher.png │ └── resources.ap_ ├── gen │ └── us │ │ └── mifan │ │ ├── BuildConfig.java │ │ └── R.java ├── libs │ ├── android-support-v4.jar │ └── commons-httpclient-3.1.jar ├── proguard-project.txt ├── project.properties ├── res │ ├── drawable-hdpi │ │ └── ic_launcher.png │ ├── drawable-mdpi │ │ ├── background_login.xml │ │ ├── background_login_div_bg.xml │ │ ├── blue_button.9.png │ │ └── ic_launcher.png │ ├── drawable-xhdpi │ │ └── ic_launcher.png │ ├── layout │ │ └── activity_login.xml │ ├── values-v11 │ │ └── styles.xml │ ├── values-v14 │ │ └── styles.xml │ └── values │ │ ├── strings.xml │ │ └── styles.xml └── src │ ├── net │ └── thinkalways │ │ └── util │ │ ├── StreamTool.java │ │ ├── StringUtils.java │ │ └── UIHelper.java │ └── us │ └── mifan │ ├── LoginActivity.java │ └── app │ ├── AppConfig.java │ ├── AppContext.java │ ├── AppException.java │ ├── AppManager.java │ ├── api │ └── ApiClient.java │ └── bean │ ├── Result.java │ └── URLs.java ├── app ├── .buildignore ├── .htaccess ├── favicon.ico ├── fonts │ ├── glyphicons-halflings-regular.eot │ ├── glyphicons-halflings-regular.svg │ ├── glyphicons-halflings-regular.ttf │ └── glyphicons-halflings-regular.woff ├── images │ ├── 404.jpg │ ├── apple-startup-5.png │ ├── apple-startup.png │ ├── apple-touch-icon-114.png │ ├── apple-touch-icon-57.png │ ├── apple-touch-icon-72.png │ ├── apple-touch-icon.png │ ├── apple-touch-iconl.png │ ├── ask-bg-2.jpg │ ├── ask-bg.jpg │ ├── avatar24.jpg │ ├── avatar35.jpg │ ├── avatar50.jpg │ ├── avatar70.jpg │ ├── beijing01.jpg │ ├── covers │ │ ├── 53cf11b58db8d258647193.jpg │ │ └── fruit_large.jpg │ ├── icon-sns.png │ ├── icon-sns@2x.png │ ├── init-loading.png │ ├── login-db.png │ ├── login-qq.png │ ├── login-wb.png │ ├── logo-bg.png │ ├── logo.png │ ├── logo@2x.png │ ├── square-bg.jpg │ └── start-up.psd ├── index.html ├── lib │ ├── es5-shim.min.js │ └── json3.min.js ├── robots.txt ├── scripts │ ├── README.md │ ├── _prefix.js │ ├── _suffix.js │ ├── app.coffee │ ├── app.js │ ├── controllers.js │ ├── controllers │ │ ├── 404.coffee │ │ ├── 404.js │ │ ├── about.coffee │ │ ├── about.js │ │ ├── firend │ │ │ ├── friend.coffee │ │ │ └── friend.js │ │ ├── global.coffee │ │ ├── global.js │ │ ├── head.coffee │ │ ├── head.js │ │ ├── home │ │ │ ├── addComment.coffee │ │ │ ├── addComment.js │ │ │ ├── addLove.coffee │ │ │ ├── addLove.js │ │ │ ├── answer.coffee │ │ │ ├── answer.js │ │ │ ├── ask.coffee │ │ │ ├── ask.js │ │ │ ├── cover.coffee │ │ │ ├── cover.js │ │ │ ├── home.coffee │ │ │ ├── home.js │ │ │ ├── homeFeed.coffee │ │ │ ├── homeFeed.js │ │ │ ├── love.coffee │ │ │ ├── love.js │ │ │ ├── news.coffee │ │ │ ├── news.js │ │ │ ├── reply.coffee │ │ │ ├── reply.js │ │ │ ├── side.coffee │ │ │ └── side.js │ │ ├── login.coffee │ │ ├── login.js │ │ ├── me │ │ │ ├── me.coffee │ │ │ ├── me.js │ │ │ ├── profile.coffee │ │ │ └── profile.js │ │ ├── mobile │ │ │ ├── bill.coffee │ │ │ ├── bill.js │ │ │ ├── design.coffee │ │ │ ├── design.js │ │ │ ├── menu.coffee │ │ │ └── menu.js │ │ ├── msg │ │ │ ├── msg.coffee │ │ │ └── msg.js │ │ ├── ques │ │ │ ├── ques.coffee │ │ │ └── ques.js │ │ ├── register.coffee │ │ ├── register.js │ │ ├── root.coffee │ │ ├── root.js │ │ ├── square │ │ │ ├── square.coffee │ │ │ └── square.js │ │ ├── user │ │ │ ├── user.coffee │ │ │ ├── user.js │ │ │ ├── userAsk.coffee │ │ │ └── userAsk.js │ │ ├── welcome.coffee │ │ └── welcome.js │ ├── defines.js │ ├── defines │ │ ├── README.md │ │ ├── api.coffee │ │ ├── api.js │ │ ├── constant.coffee │ │ ├── constant.js │ │ ├── mifan.coffee │ │ └── mifan.js │ ├── directives.js │ ├── directives │ │ ├── custom_tag.coffee │ │ ├── custom_tag.js │ │ ├── expander.coffee │ │ ├── expander.js │ │ ├── ngBlur.js │ │ ├── scroller.coffee │ │ ├── scroller.js │ │ ├── scroller.sohu.coffee │ │ ├── sub_nav.coffee │ │ ├── sub_nav.js │ │ ├── tap.coffee │ │ ├── tap.js │ │ ├── touch_href.coffee │ │ └── touch_href.js │ ├── filters.js │ ├── modules.js │ ├── services.js │ ├── services │ │ ├── emoji.coffee │ │ ├── emoji.js │ │ ├── extend.coffee │ │ ├── extend.js │ │ ├── random.coffee │ │ ├── random.js │ │ ├── storage.coffee │ │ └── storage.js │ └── tmp │ │ └── zhihu.js ├── styles │ ├── background.css │ ├── bootstrap.css │ ├── imports │ │ ├── 404.scss │ │ ├── about.scss │ │ ├── define │ │ │ ├── color.scss │ │ │ └── screen.scss │ │ ├── foot.scss │ │ ├── friend │ │ │ └── friend.scss │ │ ├── functions.scss │ │ ├── global.scss │ │ ├── head.scss │ │ ├── high-pixel-ratio.scss │ │ ├── home │ │ │ ├── home.scss │ │ │ └── side.scss │ │ ├── ipad.scss │ │ ├── log-reg.scss │ │ ├── me.scss │ │ ├── mixins.scss │ │ ├── mobile │ │ │ ├── bill.scss │ │ │ ├── bubble.scss │ │ │ ├── design.scss │ │ │ └── menu.scss │ │ ├── module │ │ │ ├── answer-form-mod.scss │ │ │ ├── face.scss │ │ │ ├── feed-actions.scss │ │ │ ├── feed.scss │ │ │ ├── load-more.scss │ │ │ ├── login-tip.scss │ │ │ ├── page.scss │ │ │ ├── pagination.scss │ │ │ ├── profile.scss │ │ │ ├── qa-cmt.scss │ │ │ ├── ques-ans.scss │ │ │ ├── ques-single-mod.scss │ │ │ ├── sns.scss │ │ │ ├── sub-nav.scss │ │ │ ├── ui-loading.scss │ │ │ ├── user-list.scss │ │ │ └── user-mod.scss │ │ ├── msg.scss │ │ ├── notification.scss │ │ ├── ques │ │ │ └── ques.scss │ │ ├── reset-bootstrap.scss │ │ ├── square │ │ │ ├── side.scss │ │ │ └── square.scss │ │ ├── toast.scss │ │ └── welcome.scss │ ├── main.scss │ └── reset.css └── views │ ├── 404.html │ ├── about.html │ ├── foot.html │ ├── friend │ ├── fans.html │ ├── follow.html │ ├── friend.html │ └── side.html │ ├── head.html │ ├── home │ ├── answer.html │ ├── home.html │ ├── love.html │ ├── news.html │ ├── reply.html │ └── side.html │ ├── login.html │ ├── me │ ├── answer.html │ ├── ask.html │ ├── love.html │ ├── me.html │ └── side.html │ ├── mobile │ ├── bill.html │ ├── design.html │ └── menu.html │ ├── module │ ├── answer-form-mod.html │ ├── answer-mod.html │ ├── feed-actions-mod.html │ ├── feed-mod.html │ ├── follow-user-mod.html │ └── ques-mod.html │ ├── msg.html │ ├── ques │ └── ques.html │ ├── register.html │ ├── search.html │ ├── square │ ├── feeds.html │ ├── side.html │ └── square.html │ ├── template │ ├── README.md │ ├── error-msg.html │ ├── logintip.html │ ├── more.html │ ├── sending-btn.html │ ├── sns-login.html │ ├── sub-nav.html │ ├── ui-loading.html │ └── usermenu.html │ └── welcome.html ├── bower.json ├── package.json └── service ├── admin └── index.html ├── application ├── cache │ ├── .htaccess │ └── index.html ├── config │ ├── acl.php │ ├── autoload.php │ ├── config.php │ ├── constants.php │ ├── database.php │ ├── doctypes.php │ ├── foreign_chars.php │ ├── hooks.php │ ├── index.html │ ├── ldap.php │ ├── memcached.php │ ├── migration.php │ ├── mimes.php │ ├── profiler.php │ ├── rest.php │ ├── routes.php │ ├── smileys.php │ └── user_agents.php ├── controllers │ ├── ask │ │ └── Askinfo.php │ ├── common │ │ └── Message.php │ ├── feed │ │ └── Feedinfo.php │ ├── group │ │ └── topic.php │ ├── index.html │ └── user │ │ ├── SaeAuth.php │ │ ├── userinfo.php │ │ └── usersession.php ├── core │ ├── MF_Controller.php │ └── index.html ├── helpers │ └── index.html ├── hooks │ ├── acl.php │ └── index.html ├── index.html ├── language │ └── english │ │ └── index.html ├── libraries │ └── index.html ├── logs │ ├── index.html │ ├── log-2014-07-13.php │ ├── log-2014-07-14.php │ └── log-2014-07-15.php ├── models │ ├── Ask_model.php │ ├── Feed_model.php │ ├── Message_model.php │ ├── base_model.php │ ├── index.html │ └── user_model.php ├── third_party │ ├── index.html │ └── rbac │ │ ├── config │ │ ├── memcached.php │ │ └── rbac.php │ │ ├── controllers │ │ ├── index.php │ │ └── manage │ │ │ ├── member.php │ │ │ ├── menu.php │ │ │ ├── node.php │ │ │ └── role.php │ │ ├── helpers │ │ └── rbac_helper.php │ │ ├── hooks │ │ ├── index.html │ │ └── rbac_hook.php │ │ ├── libraries │ │ └── memcached.php │ │ ├── models │ │ └── rbac_model.php │ │ └── views │ │ ├── foot.php │ │ ├── head.php │ │ ├── login.php │ │ ├── main.php │ │ ├── manage │ │ ├── member.php │ │ ├── member │ │ │ ├── add.php │ │ │ ├── delete.php │ │ │ └── edit.php │ │ ├── menu.php │ │ ├── menu │ │ │ ├── add.php │ │ │ ├── delete.php │ │ │ └── edit.php │ │ ├── node.php │ │ ├── node │ │ │ ├── add.php │ │ │ ├── delete.php │ │ │ └── edit.php │ │ ├── role.php │ │ └── role │ │ │ ├── action.php │ │ │ ├── add.php │ │ │ ├── delete.php │ │ │ └── edit.php │ │ ├── menu.php │ │ └── redirect.php └── views │ ├── errors │ ├── cli │ │ ├── error_404.php │ │ ├── error_db.php │ │ ├── error_general.php │ │ ├── error_php.php │ │ └── index.html │ ├── html │ │ ├── error_404.php │ │ ├── error_db.php │ │ ├── error_general.php │ │ ├── error_php.php │ │ └── index.html │ └── index.html │ └── index.html ├── cache └── user │ └── 0 │ └── 0 │ ├── 60 │ ├── 0666b88753_60_60.jpg │ ├── 4afecc5b6f_60_60.jpg │ ├── 5c7a4bc555_60_60.jpg │ ├── 6c9e391e64_60_60.jpg │ ├── 727ba6a82b_60_60.jpg │ ├── 7bc0598f90_60_60.jpg │ ├── 7dfecd76fb_60_60.png │ ├── 81962d77d0_60_60.jpg │ ├── e09e8bb0d2_60_60.jpg │ ├── e7f8839a7b_60_60.jpg │ └── f0ae5e512f_60_60.jpg │ └── 120 │ ├── 0666b88753_120_120.jpg │ ├── 4afecc5b6f_120_120.jpg │ ├── 5c7a4bc555_120_120.jpg │ ├── 6c9e391e64_120_120.jpg │ ├── 727ba6a82b_120_120.jpg │ ├── 7bc0598f90_120_120.jpg │ ├── 7dfecd76fb_120_120.png │ ├── 81962d77d0_120_120.jpg │ ├── e09e8bb0d2_120_120.jpg │ ├── e7f8839a7b_120_120.jpg │ └── f0ae5e512f_120_120.jpg ├── index.php ├── shared ├── config │ └── constant.php ├── helpers │ └── common_helper.php ├── index.html ├── language │ └── zh-cn │ │ ├── calendar_lang.php │ │ ├── date_lang.php │ │ ├── db_lang.php │ │ ├── email_lang.php │ │ ├── form_validation_lang.php │ │ ├── ftp_lang.php │ │ ├── imglib_lang.php │ │ ├── index.html │ │ ├── number_lang.php │ │ ├── profiler_lang.php │ │ ├── unit_test_lang.php │ │ └── upload_lang.php └── libraries │ ├── Form_validate.php │ ├── Format.php │ └── REST_Controller.php └── system ├── core ├── Benchmark.php ├── CodeIgniter.php ├── Common.php ├── Config.php ├── Controller.php ├── Exceptions.php ├── Hooks.php ├── Input.php ├── Lang.php ├── Loader.php ├── Log.php ├── Model.php ├── Output.php ├── Router.php ├── Security.php ├── URI.php ├── Utf8.php ├── compat │ ├── hash.php │ ├── index.html │ ├── mbstring.php │ ├── password.php │ └── standard.php └── index.html ├── database ├── DB.php ├── DB_active_rec.php ├── DB_cache.php ├── DB_driver.php ├── DB_forge.php ├── DB_query_builder.php ├── DB_result.php ├── DB_utility.php ├── drivers │ ├── cubrid │ │ ├── cubrid_driver.php │ │ ├── cubrid_forge.php │ │ ├── cubrid_result.php │ │ ├── cubrid_utility.php │ │ └── index.html │ ├── ibase │ │ ├── ibase_driver.php │ │ ├── ibase_forge.php │ │ ├── ibase_result.php │ │ ├── ibase_utility.php │ │ └── index.html │ ├── index.html │ ├── mssql │ │ ├── index.html │ │ ├── mssql_driver.php │ │ ├── mssql_forge.php │ │ ├── mssql_result.php │ │ └── mssql_utility.php │ ├── mysql │ │ ├── index.html │ │ ├── mysql_driver.php │ │ ├── mysql_forge.php │ │ ├── mysql_result.php │ │ └── mysql_utility.php │ ├── mysqli │ │ ├── index.html │ │ ├── mysqli_driver.php │ │ ├── mysqli_forge.php │ │ ├── mysqli_result.php │ │ └── mysqli_utility.php │ ├── oci8 │ │ ├── index.html │ │ ├── oci8_driver.php │ │ ├── oci8_forge.php │ │ ├── oci8_result.php │ │ └── oci8_utility.php │ ├── odbc │ │ ├── index.html │ │ ├── odbc_driver.php │ │ ├── odbc_forge.php │ │ ├── odbc_result.php │ │ └── odbc_utility.php │ ├── pdo │ │ ├── index.html │ │ ├── pdo_driver.php │ │ ├── pdo_forge.php │ │ ├── pdo_result.php │ │ ├── pdo_utility.php │ │ └── subdrivers │ │ │ ├── index.html │ │ │ ├── pdo_4d_driver.php │ │ │ ├── pdo_4d_forge.php │ │ │ ├── pdo_cubrid_driver.php │ │ │ ├── pdo_cubrid_forge.php │ │ │ ├── pdo_dblib_driver.php │ │ │ ├── pdo_dblib_forge.php │ │ │ ├── pdo_firebird_driver.php │ │ │ ├── pdo_firebird_forge.php │ │ │ ├── pdo_ibm_driver.php │ │ │ ├── pdo_ibm_forge.php │ │ │ ├── pdo_informix_driver.php │ │ │ ├── pdo_informix_forge.php │ │ │ ├── pdo_mysql_driver.php │ │ │ ├── pdo_mysql_forge.php │ │ │ ├── pdo_oci_driver.php │ │ │ ├── pdo_oci_forge.php │ │ │ ├── pdo_odbc_driver.php │ │ │ ├── pdo_odbc_forge.php │ │ │ ├── pdo_pgsql_driver.php │ │ │ ├── pdo_pgsql_forge.php │ │ │ ├── pdo_sqlite_driver.php │ │ │ ├── pdo_sqlite_forge.php │ │ │ ├── pdo_sqlsrv_driver.php │ │ │ └── pdo_sqlsrv_forge.php │ ├── postgre │ │ ├── index.html │ │ ├── postgre_driver.php │ │ ├── postgre_forge.php │ │ ├── postgre_result.php │ │ └── postgre_utility.php │ ├── sqlite │ │ ├── index.html │ │ ├── sqlite_driver.php │ │ ├── sqlite_forge.php │ │ ├── sqlite_result.php │ │ └── sqlite_utility.php │ ├── sqlite3 │ │ ├── index.html │ │ ├── sqlite3_driver.php │ │ ├── sqlite3_forge.php │ │ ├── sqlite3_result.php │ │ └── sqlite3_utility.php │ └── sqlsrv │ │ ├── index.html │ │ ├── sqlsrv_driver.php │ │ ├── sqlsrv_forge.php │ │ ├── sqlsrv_result.php │ │ └── sqlsrv_utility.php └── index.html ├── fonts ├── index.html └── texb.ttf ├── helpers ├── array_helper.php ├── captcha_helper.php ├── cookie_helper.php ├── date_helper.php ├── directory_helper.php ├── download_helper.php ├── email_helper.php ├── file_helper.php ├── form_helper.php ├── html_helper.php ├── index.html ├── inflector_helper.php ├── language_helper.php ├── number_helper.php ├── path_helper.php ├── security_helper.php ├── smiley_helper.php ├── string_helper.php ├── text_helper.php ├── typography_helper.php ├── url_helper.php └── xml_helper.php ├── index.html ├── language ├── english │ ├── calendar_lang.php │ ├── date_lang.php │ ├── db_lang.php │ ├── email_lang.php │ ├── form_validation_lang.php │ ├── ftp_lang.php │ ├── imglib_lang.php │ ├── index.html │ ├── migration_lang.php │ ├── number_lang.php │ ├── pagination_lang.php │ ├── profiler_lang.php │ ├── unit_test_lang.php │ └── upload_lang.php └── index.html └── libraries ├── Cache ├── Cache.php ├── drivers │ ├── Cache_apc.php │ ├── Cache_dummy.php │ ├── Cache_file.php │ ├── Cache_memcached.php │ ├── Cache_redis.php │ ├── Cache_wincache.php │ └── index.html └── index.html ├── Calendar.php ├── Cart.php ├── Driver.php ├── Email.php ├── Encrypt.php ├── Encryption.php ├── Form_validation.php ├── Ftp.php ├── Image_lib.php ├── Javascript.php ├── Log.php ├── Migration.php ├── Pagination.php ├── Parser.php ├── Profiler.php ├── Session.php ├── Session ├── Session.php ├── drivers │ ├── Session_cookie.php │ ├── Session_native.php │ └── index.html └── index.html ├── Sha1.php ├── Table.php ├── Trackback.php ├── Typography.php ├── Unit_test.php ├── Upload.php ├── User_agent.php ├── Xmlrpc.php ├── Xmlrpcs.php ├── Zip.php ├── index.html └── javascript ├── Jquery.php └── index.html /.bowerrc: -------------------------------------------------------------------------------- 1 | { 2 | "directory": "app/bower_components" 3 | } 4 | -------------------------------------------------------------------------------- /.editorconfig: -------------------------------------------------------------------------------- 1 | # EditorConfig helps developers define and maintain consistent 2 | # coding styles between different editors and IDEs 3 | # editorconfig.org 4 | 5 | root = true 6 | 7 | 8 | [*] 9 | 10 | # Change these settings to your own preference 11 | indent_style = space 12 | indent_size = 2 13 | 14 | # We recommend you to keep these unchanged 15 | end_of_line = lf 16 | charset = utf-8 17 | trim_trailing_whitespace = true 18 | insert_final_newline = true 19 | 20 | [*.md] 21 | trim_trailing_whitespace = false 22 | -------------------------------------------------------------------------------- /.gitattributes: -------------------------------------------------------------------------------- 1 | * text=auto -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | node_modules 2 | dist 3 | doc 4 | data 5 | emoji 6 | .tmp 7 | .sass-cache 8 | .ftppass 9 | secret.json 10 | app/bower_components 11 | app/mifan 12 | service/application/logs 13 | service/doc 14 | service/application/config/database.php 15 | service/application/cache 16 | service/uploadfile 17 | -------------------------------------------------------------------------------- /.jshintrc: -------------------------------------------------------------------------------- 1 | { 2 | "node": true, 3 | "browser": true, 4 | "esnext": true, 5 | "bitwise": true, 6 | "camelcase": true, 7 | "curly": true, 8 | "eqeqeq": true, 9 | "immed": true, 10 | "indent": 2, 11 | "latedef": true, 12 | "newcap": true, 13 | "noarg": true, 14 | "quotmark": "double|single", 15 | "regexp": true, 16 | "undef": false, 17 | "unused": true, 18 | "strict": true, 19 | "trailing": true, 20 | "smarttabs": true, 21 | "globals": { 22 | "angular": true 23 | } 24 | } 25 | -------------------------------------------------------------------------------- /.project: -------------------------------------------------------------------------------- 1 | 2 | 3 | mifan 4 | 5 | 6 | 7 | 8 | 9 | 10 | com.aptana.projects.webnature 11 | com.aptana.editor.php.phpNature 12 | 13 | 14 | -------------------------------------------------------------------------------- /.travis.yml: -------------------------------------------------------------------------------- 1 | language: node_js 2 | node_js: 3 | - '0.10' 4 | before_script: 5 | - 'npm install -g bower grunt-cli' 6 | - 'bower install' 7 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | 米饭mifan 2 | ======== 3 | 4 | 也没啥`README`的,加这个文件纯粹为了能「标配」。 5 | 6 | 拖了很久的项目,开搞而已。 7 | 8 | > 祝你幸福。 -------------------------------------------------------------------------------- /android/.classpath: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | -------------------------------------------------------------------------------- /android/.project: -------------------------------------------------------------------------------- 1 | 2 | 3 | Mifan 4 | 5 | 6 | 7 | 8 | 9 | com.android.ide.eclipse.adt.ResourceManagerBuilder 10 | 11 | 12 | 13 | 14 | com.android.ide.eclipse.adt.PreCompilerBuilder 15 | 16 | 17 | 18 | 19 | org.eclipse.jdt.core.javabuilder 20 | 21 | 22 | 23 | 24 | com.android.ide.eclipse.adt.ApkBuilder 25 | 26 | 27 | 28 | 29 | 30 | com.android.ide.eclipse.adt.AndroidNature 31 | org.eclipse.jdt.core.javanature 32 | 33 | 34 | -------------------------------------------------------------------------------- /android/.settings/org.eclipse.jdt.core.prefs: -------------------------------------------------------------------------------- 1 | eclipse.preferences.version=1 2 | org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.6 3 | org.eclipse.jdt.core.compiler.compliance=1.6 4 | org.eclipse.jdt.core.compiler.source=1.6 5 | -------------------------------------------------------------------------------- /android/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 2 | 6 | 7 | 10 | 11 | 12 | 13 | 14 | 20 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | -------------------------------------------------------------------------------- /android/bin/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 2 | 6 | 7 | 10 | 11 | 12 | 13 | 14 | 20 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | -------------------------------------------------------------------------------- /android/bin/Mifan.apk: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/android/bin/Mifan.apk -------------------------------------------------------------------------------- /android/bin/classes.dex: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/android/bin/classes.dex -------------------------------------------------------------------------------- /android/bin/classes/net/thinkalways/util/StreamTool.class: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/android/bin/classes/net/thinkalways/util/StreamTool.class -------------------------------------------------------------------------------- /android/bin/classes/net/thinkalways/util/StringUtils.class: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/android/bin/classes/net/thinkalways/util/StringUtils.class -------------------------------------------------------------------------------- /android/bin/classes/net/thinkalways/util/UIHelper.class: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/android/bin/classes/net/thinkalways/util/UIHelper.class -------------------------------------------------------------------------------- /android/bin/classes/us/mifan/BuildConfig.class: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/android/bin/classes/us/mifan/BuildConfig.class -------------------------------------------------------------------------------- /android/bin/classes/us/mifan/LoginActivity$LoginButtonClickListener$1.class: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/android/bin/classes/us/mifan/LoginActivity$LoginButtonClickListener$1.class -------------------------------------------------------------------------------- /android/bin/classes/us/mifan/LoginActivity$LoginButtonClickListener$2.class: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/android/bin/classes/us/mifan/LoginActivity$LoginButtonClickListener$2.class -------------------------------------------------------------------------------- /android/bin/classes/us/mifan/LoginActivity$LoginButtonClickListener.class: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/android/bin/classes/us/mifan/LoginActivity$LoginButtonClickListener.class -------------------------------------------------------------------------------- /android/bin/classes/us/mifan/LoginActivity.class: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/android/bin/classes/us/mifan/LoginActivity.class -------------------------------------------------------------------------------- /android/bin/classes/us/mifan/R$attr.class: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/android/bin/classes/us/mifan/R$attr.class -------------------------------------------------------------------------------- /android/bin/classes/us/mifan/R$drawable.class: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/android/bin/classes/us/mifan/R$drawable.class -------------------------------------------------------------------------------- /android/bin/classes/us/mifan/R$id.class: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/android/bin/classes/us/mifan/R$id.class -------------------------------------------------------------------------------- /android/bin/classes/us/mifan/R$layout.class: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/android/bin/classes/us/mifan/R$layout.class -------------------------------------------------------------------------------- /android/bin/classes/us/mifan/R$string.class: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/android/bin/classes/us/mifan/R$string.class -------------------------------------------------------------------------------- /android/bin/classes/us/mifan/R$style.class: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/android/bin/classes/us/mifan/R$style.class -------------------------------------------------------------------------------- /android/bin/classes/us/mifan/R.class: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/android/bin/classes/us/mifan/R.class -------------------------------------------------------------------------------- /android/bin/classes/us/mifan/app/AppConfig.class: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/android/bin/classes/us/mifan/app/AppConfig.class -------------------------------------------------------------------------------- /android/bin/classes/us/mifan/app/AppContext.class: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/android/bin/classes/us/mifan/app/AppContext.class -------------------------------------------------------------------------------- /android/bin/classes/us/mifan/app/AppException.class: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/android/bin/classes/us/mifan/app/AppException.class -------------------------------------------------------------------------------- /android/bin/classes/us/mifan/app/AppManager.class: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/android/bin/classes/us/mifan/app/AppManager.class -------------------------------------------------------------------------------- /android/bin/classes/us/mifan/app/api/ApiClient.class: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/android/bin/classes/us/mifan/app/api/ApiClient.class -------------------------------------------------------------------------------- /android/bin/classes/us/mifan/app/bean/Result.class: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/android/bin/classes/us/mifan/app/bean/Result.class -------------------------------------------------------------------------------- /android/bin/classes/us/mifan/app/bean/URLs.class: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/android/bin/classes/us/mifan/app/bean/URLs.class -------------------------------------------------------------------------------- /android/bin/dexedLibs/android-support-v4-ad00ea57bbaa4b8c1c88b9dff88a200c.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/android/bin/dexedLibs/android-support-v4-ad00ea57bbaa4b8c1c88b9dff88a200c.jar -------------------------------------------------------------------------------- /android/bin/dexedLibs/commons-httpclient-3.1-fbe8919365b212e6ac94e77c9eecb585.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/android/bin/dexedLibs/commons-httpclient-3.1-fbe8919365b212e6ac94e77c9eecb585.jar -------------------------------------------------------------------------------- /android/bin/jarlist.cache: -------------------------------------------------------------------------------- 1 | # cache for current jar dependency. DO NOT EDIT. 2 | # format is 3 | # Encoding is UTF-8 4 | -------------------------------------------------------------------------------- /android/bin/res/crunch/drawable-hdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/android/bin/res/crunch/drawable-hdpi/ic_launcher.png -------------------------------------------------------------------------------- /android/bin/res/crunch/drawable-mdpi/blue_button.9.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/android/bin/res/crunch/drawable-mdpi/blue_button.9.png -------------------------------------------------------------------------------- /android/bin/res/crunch/drawable-mdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/android/bin/res/crunch/drawable-mdpi/ic_launcher.png -------------------------------------------------------------------------------- /android/bin/res/crunch/drawable-xhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/android/bin/res/crunch/drawable-xhdpi/ic_launcher.png -------------------------------------------------------------------------------- /android/bin/resources.ap_: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/android/bin/resources.ap_ -------------------------------------------------------------------------------- /android/gen/us/mifan/BuildConfig.java: -------------------------------------------------------------------------------- 1 | /** Automatically generated file. DO NOT MODIFY */ 2 | package us.mifan; 3 | 4 | public final class BuildConfig { 5 | public final static boolean DEBUG = true; 6 | } -------------------------------------------------------------------------------- /android/libs/android-support-v4.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/android/libs/android-support-v4.jar -------------------------------------------------------------------------------- /android/libs/commons-httpclient-3.1.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/android/libs/commons-httpclient-3.1.jar -------------------------------------------------------------------------------- /android/proguard-project.txt: -------------------------------------------------------------------------------- 1 | # To enable ProGuard in your project, edit project.properties 2 | # to define the proguard.config property as described in that file. 3 | # 4 | # Add project specific ProGuard rules here. 5 | # By default, the flags in this file are appended to flags specified 6 | # in ${sdk.dir}/tools/proguard/proguard-android.txt 7 | # You can edit the include path and order by changing the ProGuard 8 | # include property in project.properties. 9 | # 10 | # For more details, see 11 | # http://developer.android.com/guide/developing/tools/proguard.html 12 | 13 | # Add any project specific keep options here: 14 | 15 | # If your project uses WebView with JS, uncomment the following 16 | # and specify the fully qualified class name to the JavaScript interface 17 | # class: 18 | #-keepclassmembers class fqcn.of.javascript.interface.for.webview { 19 | # public *; 20 | #} 21 | -------------------------------------------------------------------------------- /android/project.properties: -------------------------------------------------------------------------------- 1 | # This file is automatically generated by Android Tools. 2 | # Do not modify this file -- YOUR CHANGES WILL BE ERASED! 3 | # 4 | # This file must be checked in Version Control Systems. 5 | # 6 | # To customize properties used by the Ant build system edit 7 | # "ant.properties", and override values to adapt the script to your 8 | # project structure. 9 | # 10 | # To enable ProGuard to shrink and obfuscate your code, uncomment this (available properties: sdk.dir, user.home): 11 | #proguard.config=${sdk.dir}/tools/proguard/proguard-android.txt:proguard-project.txt 12 | 13 | # Project target. 14 | target=android-19 15 | -------------------------------------------------------------------------------- /android/res/drawable-hdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/android/res/drawable-hdpi/ic_launcher.png -------------------------------------------------------------------------------- /android/res/drawable-mdpi/background_login.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 8 | -------------------------------------------------------------------------------- /android/res/drawable-mdpi/background_login_div_bg.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 6 | 8 | -------------------------------------------------------------------------------- /android/res/drawable-mdpi/blue_button.9.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/android/res/drawable-mdpi/blue_button.9.png -------------------------------------------------------------------------------- /android/res/drawable-mdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/android/res/drawable-mdpi/ic_launcher.png -------------------------------------------------------------------------------- /android/res/drawable-xhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/android/res/drawable-xhdpi/ic_launcher.png -------------------------------------------------------------------------------- /android/res/values-v11/styles.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 7 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /android/res/values-v14/styles.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 8 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /android/res/values/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 米饭之家 5 | 6 | 登录 7 | 帐号 8 | 密码 9 | 登录 10 | 登录中... 11 | Email 12 | 密码 13 | 没有帐号? 注册 14 | 15 | 网络异常,错误码:%d 16 | 网络异常,请求超时 17 | 网络异常,读取数据超时 18 | 网络连接失败,请检查网络设置 19 | 数据解析异常 20 | 文件流异常 21 | 应用程序运行时异常 22 | 23 | 24 | -------------------------------------------------------------------------------- /android/res/values/styles.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 7 | 14 | 15 | 16 | 19 | 20 | 24 | 25 | 26 | -------------------------------------------------------------------------------- /android/src/net/thinkalways/util/StreamTool.java: -------------------------------------------------------------------------------- 1 | package net.thinkalways.util; 2 | 3 | import java.io.ByteArrayOutputStream; 4 | import java.io.IOException; 5 | import java.io.InputStream; 6 | 7 | public class StreamTool { 8 | public static byte[] read(InputStream inputStream) throws IOException{ 9 | ByteArrayOutputStream outStream = new ByteArrayOutputStream(); 10 | byte[] buffer = new byte[2048]; 11 | int len = 0; 12 | while( (len = inputStream.read(buffer)) != -1){ 13 | outStream.write(buffer, 0, len); 14 | } 15 | inputStream.close(); 16 | return outStream.toByteArray(); 17 | 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /android/src/net/thinkalways/util/StringUtils.java: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/android/src/net/thinkalways/util/StringUtils.java -------------------------------------------------------------------------------- /android/src/net/thinkalways/util/UIHelper.java: -------------------------------------------------------------------------------- 1 | package net.thinkalways.util; 2 | 3 | public class UIHelper { 4 | 5 | } 6 | -------------------------------------------------------------------------------- /android/src/us/mifan/LoginActivity.java: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/android/src/us/mifan/LoginActivity.java -------------------------------------------------------------------------------- /android/src/us/mifan/app/AppConfig.java: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/android/src/us/mifan/app/AppConfig.java -------------------------------------------------------------------------------- /android/src/us/mifan/app/AppContext.java: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/android/src/us/mifan/app/AppContext.java -------------------------------------------------------------------------------- /android/src/us/mifan/app/AppException.java: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/android/src/us/mifan/app/AppException.java -------------------------------------------------------------------------------- /android/src/us/mifan/app/AppManager.java: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/android/src/us/mifan/app/AppManager.java -------------------------------------------------------------------------------- /android/src/us/mifan/app/api/ApiClient.java: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/android/src/us/mifan/app/api/ApiClient.java -------------------------------------------------------------------------------- /android/src/us/mifan/app/bean/Result.java: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/android/src/us/mifan/app/bean/Result.java -------------------------------------------------------------------------------- /android/src/us/mifan/app/bean/URLs.java: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/android/src/us/mifan/app/bean/URLs.java -------------------------------------------------------------------------------- /app/.buildignore: -------------------------------------------------------------------------------- 1 | *.coffee -------------------------------------------------------------------------------- /app/favicon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/app/favicon.ico -------------------------------------------------------------------------------- /app/fonts/glyphicons-halflings-regular.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/app/fonts/glyphicons-halflings-regular.eot -------------------------------------------------------------------------------- /app/fonts/glyphicons-halflings-regular.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/app/fonts/glyphicons-halflings-regular.ttf -------------------------------------------------------------------------------- /app/fonts/glyphicons-halflings-regular.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/app/fonts/glyphicons-halflings-regular.woff -------------------------------------------------------------------------------- /app/images/404.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/app/images/404.jpg -------------------------------------------------------------------------------- /app/images/apple-startup-5.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/app/images/apple-startup-5.png -------------------------------------------------------------------------------- /app/images/apple-startup.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/app/images/apple-startup.png -------------------------------------------------------------------------------- /app/images/apple-touch-icon-114.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/app/images/apple-touch-icon-114.png -------------------------------------------------------------------------------- /app/images/apple-touch-icon-57.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/app/images/apple-touch-icon-57.png -------------------------------------------------------------------------------- /app/images/apple-touch-icon-72.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/app/images/apple-touch-icon-72.png -------------------------------------------------------------------------------- /app/images/apple-touch-icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/app/images/apple-touch-icon.png -------------------------------------------------------------------------------- /app/images/apple-touch-iconl.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/app/images/apple-touch-iconl.png -------------------------------------------------------------------------------- /app/images/ask-bg-2.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/app/images/ask-bg-2.jpg -------------------------------------------------------------------------------- /app/images/ask-bg.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/app/images/ask-bg.jpg -------------------------------------------------------------------------------- /app/images/avatar24.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/app/images/avatar24.jpg -------------------------------------------------------------------------------- /app/images/avatar35.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/app/images/avatar35.jpg -------------------------------------------------------------------------------- /app/images/avatar50.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/app/images/avatar50.jpg -------------------------------------------------------------------------------- /app/images/avatar70.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/app/images/avatar70.jpg -------------------------------------------------------------------------------- /app/images/beijing01.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/app/images/beijing01.jpg -------------------------------------------------------------------------------- /app/images/covers/53cf11b58db8d258647193.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/app/images/covers/53cf11b58db8d258647193.jpg -------------------------------------------------------------------------------- /app/images/covers/fruit_large.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/app/images/covers/fruit_large.jpg -------------------------------------------------------------------------------- /app/images/icon-sns.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/app/images/icon-sns.png -------------------------------------------------------------------------------- /app/images/icon-sns@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/app/images/icon-sns@2x.png -------------------------------------------------------------------------------- /app/images/init-loading.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/app/images/init-loading.png -------------------------------------------------------------------------------- /app/images/login-db.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/app/images/login-db.png -------------------------------------------------------------------------------- /app/images/login-qq.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/app/images/login-qq.png -------------------------------------------------------------------------------- /app/images/login-wb.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/app/images/login-wb.png -------------------------------------------------------------------------------- /app/images/logo-bg.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/app/images/logo-bg.png -------------------------------------------------------------------------------- /app/images/logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/app/images/logo.png -------------------------------------------------------------------------------- /app/images/logo@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/app/images/logo@2x.png -------------------------------------------------------------------------------- /app/images/square-bg.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/app/images/square-bg.jpg -------------------------------------------------------------------------------- /app/images/start-up.psd: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/app/images/start-up.psd -------------------------------------------------------------------------------- /app/robots.txt: -------------------------------------------------------------------------------- 1 | # robotstxt.org 2 | 3 | User-agent: * 4 | -------------------------------------------------------------------------------- /app/scripts/README.md: -------------------------------------------------------------------------------- 1 | * controllers.js 2 | * filters.js 3 | * directives.js 4 | 5 | 这三个文件是对应的文件夹内js合并的输出(通过grunt监听实现),不用管。 6 | 7 | * _prefix.js 8 | * _suffix.js 9 | 10 | 这两个文件是为了让所有脚本被包裹成下面的格式: 11 | 12 | ```javascript 13 | !function() { 14 | // all codes here 15 | ... 16 | }() 17 | ``` 18 | -------------------------------------------------------------------------------- /app/scripts/_prefix.js: -------------------------------------------------------------------------------- 1 | // _prefix.js 和 _suffix.js 2 | // 将JS变量包起来,实现 1)变量名压缩;2)不暴露到全局 3 | 4 | ! function() { -------------------------------------------------------------------------------- /app/scripts/_suffix.js: -------------------------------------------------------------------------------- 1 | }() -------------------------------------------------------------------------------- /app/scripts/controllers/404.coffee: -------------------------------------------------------------------------------- 1 | "use strict" 2 | 3 | Mifan.controller "404Ctrl", ($scope) -> 4 | 5 | $scope.$on "$viewContentLoaded", -> $scope.$emit "pageChange", "404" 6 | 7 | 8 | no -------------------------------------------------------------------------------- /app/scripts/controllers/404.js: -------------------------------------------------------------------------------- 1 | // Generated by CoffeeScript 1.7.1 2 | "use strict"; 3 | Mifan.controller("404Ctrl", function($scope) { 4 | $scope.$on("$viewContentLoaded", function() { 5 | return $scope.$emit("pageChange", "404"); 6 | }); 7 | return false; 8 | }); 9 | -------------------------------------------------------------------------------- /app/scripts/controllers/about.coffee: -------------------------------------------------------------------------------- 1 | "use strict" 2 | 3 | Mifan.controller "aboutCtrl", ($scope, $http) -> 4 | 5 | $scope.$on "$viewContentLoaded", -> $scope.$emit "pageChange", "about" 6 | 7 | about = 8 | 9 | init: -> 10 | 11 | about.getAbout() 12 | 13 | getAbout: -> 14 | 15 | api = "#{API.aboutsite}#{$scope.privacyParamDir}?infokey=about" 16 | api = API.aboutsite if IsDebug 17 | 18 | $http.get(api, cache: yes).success about.getAboutCb 19 | 20 | getAboutCb: (data) -> 21 | 22 | {ret, msg, result} = data 23 | 24 | $scope.site = result 25 | 26 | about.init() 27 | 28 | 29 | no -------------------------------------------------------------------------------- /app/scripts/controllers/about.js: -------------------------------------------------------------------------------- 1 | // Generated by CoffeeScript 1.7.1 2 | "use strict"; 3 | Mifan.controller("aboutCtrl", function($scope, $http) { 4 | var about; 5 | $scope.$on("$viewContentLoaded", function() { 6 | return $scope.$emit("pageChange", "about"); 7 | }); 8 | about = { 9 | init: function() { 10 | return about.getAbout(); 11 | }, 12 | getAbout: function() { 13 | var api; 14 | api = "" + API.aboutsite + $scope.privacyParamDir + "?infokey=about"; 15 | if (IsDebug) { 16 | api = API.aboutsite; 17 | } 18 | return $http.get(api, { 19 | cache: true 20 | }).success(about.getAboutCb); 21 | }, 22 | getAboutCb: function(data) { 23 | var msg, result, ret; 24 | ret = data.ret, msg = data.msg, result = data.result; 25 | return $scope.site = result; 26 | } 27 | }; 28 | about.init(); 29 | return false; 30 | }); 31 | -------------------------------------------------------------------------------- /app/scripts/controllers/global.coffee: -------------------------------------------------------------------------------- 1 | "use strict" 2 | 3 | # 最顶层的CTRL 4 | # 保存常量 5 | 6 | Mifan.controller "globalCtrl", ($scope) -> 7 | 8 | $scope.WIN = WIN 9 | $scope.DOC = DOC 10 | $scope.LOC = LOC 11 | $scope.BODY = BODY 12 | 13 | $scope.API = API 14 | 15 | 16 | # 设备 17 | $scope.IsIPhone = IsIPhone 18 | $scope.IsIPad = IsIPad 19 | $scope.IsIOS = IsIOS 20 | 21 | $scope.IsAndroid = IsAndroid 22 | $scope.IsAndroidPad = IsAndroidPad 23 | 24 | $scope.IsIEMobile = IsIEMobile 25 | 26 | $scope.IsWeixin = IsWeixin 27 | 28 | $scope.IsTouch = $scope.IsMobile = IsTouch 29 | 30 | $scope.IsChrome = IsChrome 31 | $scope.IsIE = IsIE 32 | 33 | $scope.IsPhone = IsPhone 34 | $scope.IsWebapp = IsWebapp 35 | 36 | 37 | $scope.DEFAULT_FACE = DEFAULT_FACE 38 | 39 | 40 | 41 | 42 | 43 | 44 | -------------------------------------------------------------------------------- /app/scripts/controllers/global.js: -------------------------------------------------------------------------------- 1 | // Generated by CoffeeScript 1.7.1 2 | "use strict"; 3 | Mifan.controller("globalCtrl", function($scope) { 4 | $scope.WIN = WIN; 5 | $scope.DOC = DOC; 6 | $scope.LOC = LOC; 7 | $scope.BODY = BODY; 8 | $scope.API = API; 9 | $scope.IsIPhone = IsIPhone; 10 | $scope.IsIPad = IsIPad; 11 | $scope.IsIOS = IsIOS; 12 | $scope.IsAndroid = IsAndroid; 13 | $scope.IsAndroidPad = IsAndroidPad; 14 | $scope.IsIEMobile = IsIEMobile; 15 | $scope.IsWeixin = IsWeixin; 16 | $scope.IsTouch = $scope.IsMobile = IsTouch; 17 | $scope.IsChrome = IsChrome; 18 | $scope.IsIE = IsIE; 19 | $scope.IsPhone = IsPhone; 20 | $scope.IsWebapp = IsWebapp; 21 | return $scope.DEFAULT_FACE = DEFAULT_FACE; 22 | }); 23 | -------------------------------------------------------------------------------- /app/scripts/controllers/head.coffee: -------------------------------------------------------------------------------- 1 | "use strict" 2 | Mifan.controller "headCtrl", ($scope) -> 3 | 4 | $scope.dropdownOpen = no 5 | 6 | $scope.toggleDropdown = -> $scope.dropdownOpen = not $scope.dropdownOpen; 7 | 8 | $scope.support = -> 9 | alert 1 10 | 11 | $scope.navs = [ 12 | {page: "home", text: "首页"} 13 | {page: "msg", text: "消息"} 14 | {page: "me", text: "个人主页"} 15 | {page: "friend", text: "朋友"} 16 | # {page: "hot", text: "排行"} 17 | {page: "square", text: "广场"} 18 | ] 19 | 20 | $scope.remind = "米饭新增豆瓣登录!" 21 | $scope.remind = "" 22 | 23 | 24 | 25 | 26 | # 导航三角形 27 | # $scope.arrowNav = {} 28 | 29 | # $scope.$watch "page", -> 30 | 31 | # switch $scope.page 32 | # when "home" 33 | # $scope.arrowNav = left: 23, hide: no 34 | # when "msg" 35 | # $scope.arrowNav = left: 90, hide: no 36 | # when "me" 37 | # $scope.arrowNav = left: 176, hide: no 38 | # when "friend" 39 | # $scope.arrowNav = left: 260, hide: no 40 | # else 41 | # $scope.arrowNav = left: 0, hide: yes 42 | -------------------------------------------------------------------------------- /app/scripts/controllers/head.js: -------------------------------------------------------------------------------- 1 | // Generated by CoffeeScript 1.7.1 2 | "use strict"; 3 | Mifan.controller("headCtrl", function($scope) { 4 | $scope.dropdownOpen = false; 5 | $scope.toggleDropdown = function() { 6 | return $scope.dropdownOpen = !$scope.dropdownOpen; 7 | }; 8 | $scope.support = function() { 9 | return alert(1); 10 | }; 11 | $scope.navs = [ 12 | { 13 | page: "home", 14 | text: "首页" 15 | }, { 16 | page: "msg", 17 | text: "消息" 18 | }, { 19 | page: "me", 20 | text: "个人主页" 21 | }, { 22 | page: "friend", 23 | text: "朋友" 24 | }, { 25 | page: "square", 26 | text: "广场" 27 | } 28 | ]; 29 | $scope.remind = "米饭新增豆瓣登录!"; 30 | return $scope.remind = ""; 31 | }); 32 | -------------------------------------------------------------------------------- /app/scripts/controllers/home/addLove.coffee: -------------------------------------------------------------------------------- 1 | Mifan.controller "addLoveCtrl", ($scope, $http) -> 2 | 3 | 4 | loveAns = 5 | init: -> 6 | $scope.loveAns = loveAns.send 7 | $scope.$on "loveansCb", (event, data) -> loveAns.sendCb data 8 | 9 | feed: null 10 | 11 | send: (item, point) -> 12 | return no if item.love.iflove 13 | 14 | data = 15 | answerid: item.answer.answerid 16 | 17 | loveAns.feed = item 18 | 19 | $scope.$emit "loveans", data 20 | 21 | sendCb: (data) -> 22 | {ret, msg, result} = data 23 | toastType = "" 24 | 25 | if String(ret) is "100000" 26 | if loveAns.feed 27 | loveAns.feed.love.iflove = 1 28 | loveAns.feed.answer.digg = result 29 | 30 | msg = "喜欢成功" 31 | else 32 | toastType = "warn" 33 | 34 | $scope.toast msg, toastType 35 | 36 | loveAns.init() -------------------------------------------------------------------------------- /app/scripts/controllers/home/addLove.js: -------------------------------------------------------------------------------- 1 | // Generated by CoffeeScript 1.7.1 2 | Mifan.controller("addLoveCtrl", function($scope, $http) { 3 | var loveAns; 4 | loveAns = { 5 | init: function() { 6 | $scope.loveAns = loveAns.send; 7 | return $scope.$on("loveansCb", function(event, data) { 8 | return loveAns.sendCb(data); 9 | }); 10 | }, 11 | feed: null, 12 | send: function(item, point) { 13 | var data; 14 | if (item.love.iflove) { 15 | return false; 16 | } 17 | data = { 18 | answerid: item.answer.answerid 19 | }; 20 | loveAns.feed = item; 21 | return $scope.$emit("loveans", data); 22 | }, 23 | sendCb: function(data) { 24 | var msg, result, ret, toastType; 25 | ret = data.ret, msg = data.msg, result = data.result; 26 | toastType = ""; 27 | if (String(ret) === "100000") { 28 | if (loveAns.feed) { 29 | loveAns.feed.love.iflove = 1; 30 | loveAns.feed.answer.digg = result; 31 | } 32 | msg = "喜欢成功"; 33 | } else { 34 | toastType = "warn"; 35 | } 36 | return $scope.toast(msg, toastType); 37 | } 38 | }; 39 | return loveAns.init(); 40 | }); 41 | -------------------------------------------------------------------------------- /app/scripts/controllers/home/answer.coffee: -------------------------------------------------------------------------------- 1 | 2 | Mifan.controller "homeAnswer", ($scope, $http) -> 3 | $scope.$emit "clearAnswerRemind" 4 | 5 | $scope.ansMeCollect = [] 6 | 7 | news = 8 | init: -> 9 | news.get() 10 | 11 | $scope.getPage = news.get 12 | 13 | 14 | get: (page = 1) -> 15 | 16 | url = "#{API.answerme}#{$scope.privacyParamDir}/page/#{page}" 17 | url = API.answerme if IsDebug 18 | 19 | $scope.$emit "onPaginationStartChange", page 20 | 21 | cb = (data) -> 22 | {ret, result} = data 23 | 24 | if result 25 | $scope.ansMeCollect = result['list'] 26 | 27 | $scope.$emit "onPaginationGeted", result['page'] 28 | 29 | else 30 | $scope.errorMsg = data.msg 31 | 32 | 33 | $scope.dataLoaded = yes 34 | 35 | 36 | $http.get(url).success cb 37 | 38 | news.init() 39 | 40 | 41 | -------------------------------------------------------------------------------- /app/scripts/controllers/home/answer.js: -------------------------------------------------------------------------------- 1 | // Generated by CoffeeScript 1.7.1 2 | Mifan.controller("homeAnswer", function($scope, $http) { 3 | var news; 4 | $scope.$emit("clearAnswerRemind"); 5 | $scope.ansMeCollect = []; 6 | news = { 7 | init: function() { 8 | news.get(); 9 | return $scope.getPage = news.get; 10 | }, 11 | get: function(page) { 12 | var cb, url; 13 | if (page == null) { 14 | page = 1; 15 | } 16 | url = "" + API.answerme + $scope.privacyParamDir + "/page/" + page; 17 | if (IsDebug) { 18 | url = API.answerme; 19 | } 20 | $scope.$emit("onPaginationStartChange", page); 21 | cb = function(data) { 22 | var result, ret; 23 | ret = data.ret, result = data.result; 24 | if (result) { 25 | $scope.ansMeCollect = result['list']; 26 | $scope.$emit("onPaginationGeted", result['page']); 27 | } else { 28 | $scope.errorMsg = data.msg; 29 | } 30 | return $scope.dataLoaded = true; 31 | }; 32 | return $http.get(url).success(cb); 33 | } 34 | }; 35 | return news.init(); 36 | }); 37 | -------------------------------------------------------------------------------- /app/scripts/controllers/home/ask.coffee: -------------------------------------------------------------------------------- 1 | "use strict" 2 | 3 | Mifan.controller "homeAskCtrl", ($scope, $timeout) -> 4 | 5 | $scope.quesContent = "" 6 | #$scope.avatarUrl = "http://tp4.sinaimg.cn/2005321383/180/5698650002/1" 7 | 8 | $scope.isSending = no 9 | 10 | # $scope.onFocus = -> $scope.onInputing = yes 11 | # $scope.onBlur = (force) -> 12 | # if force or $scope.askQuesConent is "" 13 | # $scope.onInputing = $scope.isSending = no 14 | 15 | $scope.send = -> 16 | $scope.isSending = yes 17 | 18 | $scope.askQues 19 | content: $scope.quesContent 20 | 21 | clearAsk = -> 22 | $scope.isSending = no 23 | $timeout -> 24 | $scope.isSendSucs = no 25 | , 1000 26 | 27 | 28 | $scope.$on "onAskQuesSuccess", (event, msg) -> 29 | $scope.quesContent = "" 30 | $scope.isSendSucs = yes 31 | $scope.toast "提问成功!" 32 | 33 | clearAsk() 34 | 35 | $scope.$on "onAskQuesFail", (event, msg) -> 36 | $scope.toast msg.msg, "warn" 37 | clearAsk() -------------------------------------------------------------------------------- /app/scripts/controllers/home/ask.js: -------------------------------------------------------------------------------- 1 | // Generated by CoffeeScript 1.7.1 2 | "use strict"; 3 | Mifan.controller("homeAskCtrl", function($scope, $timeout) { 4 | var clearAsk; 5 | $scope.quesContent = ""; 6 | $scope.isSending = false; 7 | $scope.send = function() { 8 | $scope.isSending = true; 9 | return $scope.askQues({ 10 | content: $scope.quesContent 11 | }); 12 | }; 13 | clearAsk = function() { 14 | $scope.isSending = false; 15 | return $timeout(function() { 16 | return $scope.isSendSucs = false; 17 | }, 1000); 18 | }; 19 | $scope.$on("onAskQuesSuccess", function(event, msg) { 20 | $scope.quesContent = ""; 21 | $scope.isSendSucs = true; 22 | $scope.toast("提问成功!"); 23 | return clearAsk(); 24 | }); 25 | return $scope.$on("onAskQuesFail", function(event, msg) { 26 | $scope.toast(msg.msg, "warn"); 27 | return clearAsk(); 28 | }); 29 | }); 30 | -------------------------------------------------------------------------------- /app/scripts/controllers/home/cover.coffee: -------------------------------------------------------------------------------- 1 | Mifan.controller "homeCoverCtrl", ($scope, $timeout) -> 2 | 3 | $scope.bgUrl = "images/covers/fruit_large.jpg" -------------------------------------------------------------------------------- /app/scripts/controllers/home/cover.js: -------------------------------------------------------------------------------- 1 | // Generated by CoffeeScript 1.7.1 2 | Mifan.controller("homeCoverCtrl", function($scope, $timeout) { 3 | return $scope.bgUrl = "images/covers/fruit_large.jpg"; 4 | }); 5 | -------------------------------------------------------------------------------- /app/scripts/controllers/home/home.coffee: -------------------------------------------------------------------------------- 1 | "use strict" 2 | 3 | Mifan.controller "homeCtrl", ["$scope", "$routeParams", ($scope, $routeParams) -> 4 | 5 | legalFeedTypes = [ 6 | "news" 7 | "answer" 8 | "reply" 9 | "love" 10 | ] 11 | 12 | setCaretLeft = (type) -> 13 | index = legalFeedTypes.indexOf type 14 | $scope.caretLeft = "#{index * 25}%" 15 | 16 | $scope.legalFeedTypes = legalFeedTypes 17 | 18 | $scope.caretLeft = "0" 19 | 20 | # 过滤不合法的URL 21 | if 0 > legalFeedTypes.indexOf $routeParams.type 22 | $routeParams.type = "news" 23 | 24 | $scope.feedType = $routeParams.type 25 | 26 | $scope.$on "$viewContentLoaded", -> $scope.$emit "pageChange", "home" 27 | 28 | $scope.remind = 29 | newsNum: 0 30 | answerNum: 2 31 | replyNum: '...' 32 | loveNum: 0 33 | 34 | # 清除提醒 35 | $scope.$on "clearAnswerRemind", -> $scope.remind.answerNum = 0 36 | $scope.$on "clearReplyRemind", -> $scope.remind.replyNum = 0 37 | 38 | # 加载更多 39 | $scope.loadingMore = -> 40 | $scope.isLoading = yes 41 | 42 | $scope.switchFeed = (type) -> 43 | type = type or "news" 44 | 45 | $scope.feedType = type 46 | $scope.isLoading = no 47 | $scope.dataLoaded = no 48 | 49 | setCaretLeft(type) 50 | 51 | $scope.$emit "onClearPaginationData" 52 | 53 | no 54 | ] 55 | 56 | 57 | -------------------------------------------------------------------------------- /app/scripts/controllers/home/home.js: -------------------------------------------------------------------------------- 1 | // Generated by CoffeeScript 1.7.1 2 | "use strict"; 3 | Mifan.controller("homeCtrl", [ 4 | "$scope", "$routeParams", function($scope, $routeParams) { 5 | var legalFeedTypes, setCaretLeft; 6 | legalFeedTypes = ["news", "answer", "reply", "love"]; 7 | setCaretLeft = function(type) { 8 | var index; 9 | index = legalFeedTypes.indexOf(type); 10 | return $scope.caretLeft = "" + (index * 25) + "%"; 11 | }; 12 | $scope.legalFeedTypes = legalFeedTypes; 13 | $scope.caretLeft = "0"; 14 | if (0 > legalFeedTypes.indexOf($routeParams.type)) { 15 | $routeParams.type = "news"; 16 | } 17 | $scope.feedType = $routeParams.type; 18 | $scope.$on("$viewContentLoaded", function() { 19 | return $scope.$emit("pageChange", "home"); 20 | }); 21 | $scope.remind = { 22 | newsNum: 0, 23 | answerNum: 2, 24 | replyNum: '...', 25 | loveNum: 0 26 | }; 27 | $scope.$on("clearAnswerRemind", function() { 28 | return $scope.remind.answerNum = 0; 29 | }); 30 | $scope.$on("clearReplyRemind", function() { 31 | return $scope.remind.replyNum = 0; 32 | }); 33 | $scope.loadingMore = function() { 34 | return $scope.isLoading = true; 35 | }; 36 | $scope.switchFeed = function(type) { 37 | type = type || "news"; 38 | $scope.feedType = type; 39 | $scope.isLoading = false; 40 | $scope.dataLoaded = false; 41 | setCaretLeft(type); 42 | return $scope.$emit("onClearPaginationData"); 43 | }; 44 | return false; 45 | } 46 | ]); 47 | -------------------------------------------------------------------------------- /app/scripts/controllers/home/homeFeed.coffee: -------------------------------------------------------------------------------- 1 | 2 | Mifan.controller "homeFeed", ($scope, $http) -> 3 | 4 | feed = 5 | init: -> 6 | 7 | 8 | feed.init() 9 | 10 | $scope.toggleMBubble = (index) -> 11 | $scope.newsCollect[index].bblActv = not $scope.newsCollect[index].bblActv 12 | 13 | $scope.setMBill = (index) -> 14 | 15 | $scope.toggleMBill ["love", "comment", "share"] 16 | 17 | 18 | 19 | 20 | -------------------------------------------------------------------------------- /app/scripts/controllers/home/homeFeed.js: -------------------------------------------------------------------------------- 1 | // Generated by CoffeeScript 1.7.1 2 | Mifan.controller("homeFeed", function($scope, $http) { 3 | var feed; 4 | feed = { 5 | init: function() {} 6 | }; 7 | feed.init(); 8 | $scope.toggleMBubble = function(index) { 9 | return $scope.newsCollect[index].bblActv = !$scope.newsCollect[index].bblActv; 10 | }; 11 | return $scope.setMBill = function(index) { 12 | return $scope.toggleMBill(["love", "comment", "share"]); 13 | }; 14 | }); 15 | -------------------------------------------------------------------------------- /app/scripts/controllers/home/love.coffee: -------------------------------------------------------------------------------- 1 | 2 | Mifan.controller "homeLove", ($scope, $http) -> 3 | $scope.$emit "clearLoveRemind" 4 | 5 | API = $scope.API 6 | 7 | # Ajax取到数据进行缓存,用户手动刷新 8 | $scope.content = "" 9 | 10 | $scope.newsCollect = [] 11 | 12 | news = 13 | 14 | init: -> 15 | 16 | $scope.getPage = news.get 17 | 18 | news.get 1 19 | 20 | 21 | get: (page) -> 22 | 23 | return no if $scope.isPageLoading 24 | 25 | url = "#{API.lovemefeed}#{$scope.privacyParamDir}/page/#{page}" 26 | url = API.lovemefeed if IsDebug 27 | 28 | $scope.$emit "onPaginationStartChange", page 29 | 30 | cb = (data) -> 31 | 32 | {ret, result, msg} = data 33 | 34 | if result and result.page 35 | newsCollect = result['list'] 36 | 37 | news.feedMod = "loveme" for news in newsCollect 38 | 39 | $scope.newsCollect = newsCollect 40 | 41 | pageData = result['page'] 42 | 43 | $scope.$emit "onPaginationGeted", pageData if pageData 44 | 45 | else 46 | $scope.errorMsg = msg 47 | 48 | 49 | $scope.dataLoaded = yes 50 | 51 | 52 | 53 | 54 | $http.get(url).success cb 55 | 56 | 57 | news.init() 58 | -------------------------------------------------------------------------------- /app/scripts/controllers/home/love.js: -------------------------------------------------------------------------------- 1 | // Generated by CoffeeScript 1.7.1 2 | Mifan.controller("homeLove", function($scope, $http) { 3 | var API, news; 4 | $scope.$emit("clearLoveRemind"); 5 | API = $scope.API; 6 | $scope.content = ""; 7 | $scope.newsCollect = []; 8 | news = { 9 | init: function() { 10 | $scope.getPage = news.get; 11 | return news.get(1); 12 | }, 13 | get: function(page) { 14 | var cb, url; 15 | if ($scope.isPageLoading) { 16 | return false; 17 | } 18 | url = "" + API.lovemefeed + $scope.privacyParamDir + "/page/" + page; 19 | if (IsDebug) { 20 | url = API.lovemefeed; 21 | } 22 | $scope.$emit("onPaginationStartChange", page); 23 | cb = function(data) { 24 | var msg, newsCollect, pageData, result, ret, _i, _len; 25 | ret = data.ret, result = data.result, msg = data.msg; 26 | if (result && result.page) { 27 | newsCollect = result['list']; 28 | for (_i = 0, _len = newsCollect.length; _i < _len; _i++) { 29 | news = newsCollect[_i]; 30 | news.feedMod = "loveme"; 31 | } 32 | $scope.newsCollect = newsCollect; 33 | pageData = result['page']; 34 | if (pageData) { 35 | $scope.$emit("onPaginationGeted", pageData); 36 | } 37 | } else { 38 | $scope.errorMsg = msg; 39 | } 40 | return $scope.dataLoaded = true; 41 | }; 42 | return $http.get(url).success(cb); 43 | } 44 | }; 45 | return news.init(); 46 | }); 47 | -------------------------------------------------------------------------------- /app/scripts/controllers/home/news.coffee: -------------------------------------------------------------------------------- 1 | 2 | Mifan.controller "homeNews", ($scope, $timeout, $http, $time) -> 3 | 4 | API = $scope.API 5 | 6 | # ajax取到数据进行缓存,用户手动刷新 7 | $scope.content = "" 8 | 9 | $scope.newsCollect = [] 10 | 11 | news = 12 | 13 | init: -> 14 | 15 | getFirstPage = -> 16 | news.get 1 17 | 18 | # 接受验证登录成功 19 | $scope.$on "getHomeNews", getFirstPage 20 | getFirstPage() if $scope.isLogin 21 | 22 | $scope.getPage = news.get 23 | 24 | 25 | get: (page) -> 26 | 27 | return no if $scope.isPageLoading 28 | 29 | url = "#{API.news}#{$scope.privacyParamDir}/page/#{page}" 30 | url = API.news if IsDebug 31 | 32 | $scope.$emit "onPaginationStartChange", page 33 | 34 | cb = (data) -> 35 | 36 | {ret, result, msg} = data 37 | 38 | if result and result.page 39 | $scope.newsCollect = result['list'] 40 | 41 | $scope.$emit "onPaginationGeted", result['page'] 42 | else 43 | $scope.errorMsg = msg 44 | 45 | $scope.dataLoaded = yes 46 | 47 | 48 | $http.get(url).success cb 49 | 50 | 51 | news.init() 52 | 53 | 54 | 55 | -------------------------------------------------------------------------------- /app/scripts/controllers/home/news.js: -------------------------------------------------------------------------------- 1 | // Generated by CoffeeScript 1.7.1 2 | Mifan.controller("homeNews", function($scope, $timeout, $http, $time) { 3 | var API, news; 4 | API = $scope.API; 5 | $scope.content = ""; 6 | $scope.newsCollect = []; 7 | news = { 8 | init: function() { 9 | var getFirstPage; 10 | getFirstPage = function() { 11 | return news.get(1); 12 | }; 13 | $scope.$on("getHomeNews", getFirstPage); 14 | if ($scope.isLogin) { 15 | getFirstPage(); 16 | } 17 | return $scope.getPage = news.get; 18 | }, 19 | get: function(page) { 20 | var cb, url; 21 | if ($scope.isPageLoading) { 22 | return false; 23 | } 24 | url = "" + API.news + $scope.privacyParamDir + "/page/" + page; 25 | if (IsDebug) { 26 | url = API.news; 27 | } 28 | $scope.$emit("onPaginationStartChange", page); 29 | cb = function(data) { 30 | var msg, result, ret; 31 | ret = data.ret, result = data.result, msg = data.msg; 32 | if (result && result.page) { 33 | $scope.newsCollect = result['list']; 34 | $scope.$emit("onPaginationGeted", result['page']); 35 | } else { 36 | $scope.errorMsg = msg; 37 | } 38 | return $scope.dataLoaded = true; 39 | }; 40 | return $http.get(url).success(cb); 41 | } 42 | }; 43 | return news.init(); 44 | }); 45 | -------------------------------------------------------------------------------- /app/scripts/controllers/home/reply.coffee: -------------------------------------------------------------------------------- 1 | 2 | Mifan.controller "homeReply", ($scope, $http) -> 3 | 4 | $scope.$emit "clearReplyRemind" 5 | 6 | API = $scope.API 7 | 8 | # Ajax取到数据进行缓存,用户手动刷新 9 | $scope.content = "" 10 | 11 | $scope.newsCollect = [] 12 | 13 | news = 14 | 15 | init: -> 16 | 17 | $scope.getPage = news.get 18 | 19 | news.get 1 20 | 21 | 22 | get: (page) -> 23 | 24 | return no if $scope.isPageLoading 25 | 26 | url = "#{API.commentme}#{$scope.privacyParamDir}/page/#{page}" 27 | url = API.commentme if IsDebug 28 | 29 | $scope.$emit "onPaginationStartChange", page 30 | 31 | cb = (data) -> 32 | 33 | {ret, result} = data 34 | 35 | if result and result.page 36 | newsCollect = result['list'] 37 | 38 | for news in newsCollect 39 | news.feedMod = "replyme" 40 | 41 | news["commentList"] = [news.comment] 42 | 43 | $scope.newsCollect = newsCollect 44 | 45 | pageData = result['page'] 46 | 47 | $scope.$emit "onPaginationGeted", pageData if pageData 48 | 49 | else 50 | $scope.errorMsg = data.msg 51 | 52 | $scope.dataLoaded = yes 53 | 54 | 55 | $http.get(url).success cb 56 | 57 | 58 | news.init() -------------------------------------------------------------------------------- /app/scripts/controllers/home/reply.js: -------------------------------------------------------------------------------- 1 | // Generated by CoffeeScript 1.7.1 2 | Mifan.controller("homeReply", function($scope, $http) { 3 | var API, news; 4 | $scope.$emit("clearReplyRemind"); 5 | API = $scope.API; 6 | $scope.content = ""; 7 | $scope.newsCollect = []; 8 | news = { 9 | init: function() { 10 | $scope.getPage = news.get; 11 | return news.get(1); 12 | }, 13 | get: function(page) { 14 | var cb, url; 15 | if ($scope.isPageLoading) { 16 | return false; 17 | } 18 | url = "" + API.commentme + $scope.privacyParamDir + "/page/" + page; 19 | if (IsDebug) { 20 | url = API.commentme; 21 | } 22 | $scope.$emit("onPaginationStartChange", page); 23 | cb = function(data) { 24 | var newsCollect, pageData, result, ret, _i, _len; 25 | ret = data.ret, result = data.result; 26 | if (result && result.page) { 27 | newsCollect = result['list']; 28 | for (_i = 0, _len = newsCollect.length; _i < _len; _i++) { 29 | news = newsCollect[_i]; 30 | news.feedMod = "replyme"; 31 | news["commentList"] = [news.comment]; 32 | } 33 | $scope.newsCollect = newsCollect; 34 | pageData = result['page']; 35 | if (pageData) { 36 | $scope.$emit("onPaginationGeted", pageData); 37 | } 38 | } else { 39 | $scope.errorMsg = data.msg; 40 | } 41 | return $scope.dataLoaded = true; 42 | }; 43 | return $http.get(url).success(cb); 44 | } 45 | }; 46 | return news.init(); 47 | }); 48 | -------------------------------------------------------------------------------- /app/scripts/controllers/home/side.coffee: -------------------------------------------------------------------------------- 1 | "use strict" 2 | 3 | Mifan.controller "homeSideCtrl", ($scope) -> 4 | 5 | $scope.mifanAskContent = "情人节和谁过的?" -------------------------------------------------------------------------------- /app/scripts/controllers/home/side.js: -------------------------------------------------------------------------------- 1 | // Generated by CoffeeScript 1.7.1 2 | "use strict"; 3 | Mifan.controller("homeSideCtrl", function($scope) { 4 | return $scope.mifanAskContent = "情人节和谁过的?"; 5 | }); 6 | -------------------------------------------------------------------------------- /app/scripts/controllers/me/profile.coffee: -------------------------------------------------------------------------------- 1 | "use strict" 2 | 3 | Mifan.controller "profileCtrl", ($scope) -> 4 | 5 | 6 | -------------------------------------------------------------------------------- /app/scripts/controllers/me/profile.js: -------------------------------------------------------------------------------- 1 | // Generated by CoffeeScript 1.7.1 2 | "use strict"; 3 | Mifan.controller("profileCtrl", function($scope) {}); 4 | -------------------------------------------------------------------------------- /app/scripts/controllers/mobile/bill.coffee: -------------------------------------------------------------------------------- 1 | Mifan.controller "mBillCtrl", ($scope) -> 2 | 3 | billListMap = 4 | "love": 5 | name: "喜欢" 6 | 7 | "comment": 8 | name: "评论" 9 | fn: "toggleMDesign('comment')" 10 | 11 | "share": 12 | name: "分享" 13 | 14 | "answer": 15 | name: "回答" 16 | fn: "toggleMDesign('answer')" 17 | 18 | 19 | $scope.billList = [] 20 | 21 | $scope.$on "setBillList", (event, msg) -> 22 | $scope.billList = (billListMap[type] for type in msg) -------------------------------------------------------------------------------- /app/scripts/controllers/mobile/bill.js: -------------------------------------------------------------------------------- 1 | // Generated by CoffeeScript 1.7.1 2 | Mifan.controller("mBillCtrl", function($scope) { 3 | var billListMap; 4 | billListMap = { 5 | "love": { 6 | name: "喜欢" 7 | }, 8 | "comment": { 9 | name: "评论", 10 | fn: "toggleMDesign('comment')" 11 | }, 12 | "share": { 13 | name: "分享" 14 | }, 15 | "answer": { 16 | name: "回答", 17 | fn: "toggleMDesign('answer')" 18 | } 19 | }; 20 | $scope.billList = []; 21 | return $scope.$on("setBillList", function(event, msg) { 22 | var type; 23 | return $scope.billList = (function() { 24 | var _i, _len, _results; 25 | _results = []; 26 | for (_i = 0, _len = msg.length; _i < _len; _i++) { 27 | type = msg[_i]; 28 | _results.push(billListMap[type]); 29 | } 30 | return _results; 31 | })(); 32 | }); 33 | }); 34 | -------------------------------------------------------------------------------- /app/scripts/controllers/mobile/design.coffee: -------------------------------------------------------------------------------- 1 | Mifan.controller "mDesginCtrl", ($scope, $timeout) -> 2 | 3 | DOC = $scope.DOC 4 | 5 | elMDesignTextarea = DOC["getElementById"] "m-design-input" 6 | 7 | titleMap = 8 | "ask": "提出问题" 9 | "comment": "评论" 10 | "answer": "回答" 11 | 12 | $scope.mDesignContent = "" 13 | 14 | sendData = {} 15 | 16 | # 设置展示界面类型 17 | # ask => 提问 18 | # comment => 评论 19 | # 20 | $scope.$on "setMDesignType", (evet, msg) -> 21 | $scope.viewType = msg 22 | $scope.title = titleMap[msg] 23 | 24 | switch msg 25 | when "ask" 26 | sendData = 27 | type: msg 28 | content: $scope.mDesignContent 29 | 30 | $timeout -> 31 | elMDesignTextarea.focus() 32 | , 800 33 | 34 | # 取消内容发送的展示 35 | # 实际上后台还会继续网络请求发送 36 | $scope.$on "cancelMDesingSending", -> 37 | $scope.isSending = no 38 | $scope.mDesignContent = "" 39 | 40 | $scope.onSubmit = -> 41 | $scope.isSending = yes 42 | $scope.$emit "onMDesignSend", sendData 43 | 44 | 45 | $scope.$on "onMDesignSendSuccess", (event, msg) -> 46 | $scope.mDesignContent = "" 47 | 48 | $scope.isSending = no 49 | $scope.isSendSucs = yes 50 | 51 | $timeout -> 52 | $scope.isSendSucs = no 53 | $scope.toggleMDesign() if $scope.isMDesignOpen 54 | , 800 55 | 56 | -------------------------------------------------------------------------------- /app/scripts/controllers/mobile/design.js: -------------------------------------------------------------------------------- 1 | // Generated by CoffeeScript 1.7.1 2 | Mifan.controller("mDesginCtrl", function($scope, $timeout) { 3 | var DOC, elMDesignTextarea, sendData, titleMap; 4 | DOC = $scope.DOC; 5 | elMDesignTextarea = DOC["getElementById"]("m-design-input"); 6 | titleMap = { 7 | "ask": "提出问题", 8 | "comment": "评论", 9 | "answer": "回答" 10 | }; 11 | $scope.mDesignContent = ""; 12 | sendData = {}; 13 | $scope.$on("setMDesignType", function(evet, msg) { 14 | $scope.viewType = msg; 15 | $scope.title = titleMap[msg]; 16 | switch (msg) { 17 | case "ask": 18 | sendData = { 19 | type: msg, 20 | content: $scope.mDesignContent 21 | }; 22 | } 23 | return $timeout(function() { 24 | return elMDesignTextarea.focus(); 25 | }, 800); 26 | }); 27 | $scope.$on("cancelMDesingSending", function() { 28 | $scope.isSending = false; 29 | return $scope.mDesignContent = ""; 30 | }); 31 | $scope.onSubmit = function() { 32 | $scope.isSending = true; 33 | return $scope.$emit("onMDesignSend", sendData); 34 | }; 35 | return $scope.$on("onMDesignSendSuccess", function(event, msg) { 36 | $scope.mDesignContent = ""; 37 | $scope.isSending = false; 38 | $scope.isSendSucs = true; 39 | return $timeout(function() { 40 | $scope.isSendSucs = false; 41 | if ($scope.isMDesignOpen) { 42 | return $scope.toggleMDesign(); 43 | } 44 | }, 800); 45 | }); 46 | }); 47 | -------------------------------------------------------------------------------- /app/scripts/controllers/mobile/menu.coffee: -------------------------------------------------------------------------------- 1 | 2 | Mifan.controller "mMenuCtrl", ($scope, $timeout) -> 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /app/scripts/controllers/mobile/menu.js: -------------------------------------------------------------------------------- 1 | // Generated by CoffeeScript 1.7.1 2 | Mifan.controller("mMenuCtrl", function($scope, $timeout) {}); 3 | -------------------------------------------------------------------------------- /app/scripts/controllers/ques/ques.coffee: -------------------------------------------------------------------------------- 1 | "use strict" 2 | Mifan.controller "quesDetailCtrl", ($scope, $timeout, $http, $routeParams, $location) -> 3 | 4 | $scope.$on "$viewContentLoaded", -> $scope.$emit "pageChange", "ques" 5 | 6 | askid = $routeParams.id 7 | 8 | ques = 9 | init: -> 10 | ques.getInfo askid 11 | ques.getAns 1 12 | 13 | $scope.$on "onGetAskInfoCb", (e, data) -> 14 | ques.getInfoCb data 15 | 16 | $scope.$on "onGetAskAnswersCb", (e, data) -> 17 | ques.getAnsCb data 18 | 19 | $scope.getPage = ques.getAns 20 | 21 | getInfo: (askid) -> 22 | $scope.$emit "onGetAskInfo", askid 23 | 24 | getInfoCb: (data) -> 25 | {ret, result} = data 26 | 27 | if String(ret) is "100000" 28 | $scope.askInfo = result 29 | 30 | $scope.dataInfoLoaded = yes 31 | 32 | getAns: (page = 1) -> 33 | $scope.$emit "onGetAskAnswers", askid: askid, page: page 34 | $scope.$emit "onPaginationStartChange", page 35 | 36 | 37 | getAnsCb: (data) -> 38 | {ret, result} = data 39 | if String(ret) is "100000" 40 | askAns = result["list"] 41 | 42 | ans.ask = askid: askid for ans in askAns 43 | 44 | $scope.askAns = askAns 45 | 46 | $scope.$emit "onPaginationGeted", result["page"] 47 | 48 | $scope.dataLoaded = yes 49 | 50 | 51 | 52 | 53 | ques.init() 54 | 55 | 56 | 57 | 58 | 59 | 60 | 61 | 62 | 63 | 64 | -------------------------------------------------------------------------------- /app/scripts/controllers/user/userAsk.coffee: -------------------------------------------------------------------------------- 1 | Mifan.controller "userAskCtrl", ($scope, $timeout, $http, $debug, $routeParams) -> 2 | 3 | # 向TA提问 4 | $scope.quesContent = "" 5 | 6 | userid = $routeParams.id 7 | 8 | $scope.send = -> 9 | $scope.isSending = yes 10 | $scope.askQues 11 | content: $scope.quesContent 12 | foruser: userid 13 | 14 | $scope.$on "onAskQuesSuccess", (event, msg) -> 15 | $scope.quesContent = "" 16 | $scope.isSending = no 17 | $scope.isSendSucs = yes 18 | 19 | $timeout -> 20 | $scope.isSendSucs = $scope.showAskBox = no 21 | , 1000 22 | 23 | $scope.toast "提问成功!" 24 | 25 | $scope.$on "onAskQuesFail", (event, msg) -> 26 | $scope.toast msg.msg 27 | $scope.isSending = no 28 | $timeout -> 29 | $scope.isSendSucs = no 30 | , 1000 -------------------------------------------------------------------------------- /app/scripts/controllers/user/userAsk.js: -------------------------------------------------------------------------------- 1 | // Generated by CoffeeScript 1.7.1 2 | Mifan.controller("userAskCtrl", function($scope, $timeout, $http, $debug, $routeParams) { 3 | var userid; 4 | $scope.quesContent = ""; 5 | userid = $routeParams.id; 6 | $scope.send = function() { 7 | $scope.isSending = true; 8 | return $scope.askQues({ 9 | content: $scope.quesContent, 10 | foruser: userid 11 | }); 12 | }; 13 | $scope.$on("onAskQuesSuccess", function(event, msg) { 14 | $scope.quesContent = ""; 15 | $scope.isSending = false; 16 | $scope.isSendSucs = true; 17 | $timeout(function() { 18 | return $scope.isSendSucs = $scope.showAskBox = false; 19 | }, 1000); 20 | return $scope.toast("提问成功!"); 21 | }); 22 | return $scope.$on("onAskQuesFail", function(event, msg) { 23 | $scope.toast(msg.msg); 24 | $scope.isSending = false; 25 | return $timeout(function() { 26 | return $scope.isSendSucs = false; 27 | }, 1000); 28 | }); 29 | }); 30 | -------------------------------------------------------------------------------- /app/scripts/controllers/welcome.coffee: -------------------------------------------------------------------------------- 1 | "use strict" 2 | 3 | Mifan.controller "welcomeCtrl", [ "$scope", ($scope) -> 4 | 5 | $scope.$on "$viewContentLoaded", -> $scope.$emit "pageChange", "welcome" 6 | 7 | $scope.$watch "email + password", -> 8 | $scope.isLoginValid = $scope.email and $scope.password 9 | 10 | # 是不是在登录界面 11 | $scope.isLoginBox = no 12 | 13 | # 是不是正在登录,等待服务器返回登录状态 14 | $scope.isLoging = no 15 | $scope.isReging = no 16 | 17 | $scope.toggleLogin = -> $scope.isLoginBox = !$scope.isLoginBox 18 | 19 | $scope.loginSubmit = -> 20 | $scope.isLoging = yes 21 | 22 | $scope.regSubmit = -> 23 | $scope.isReging = yes 24 | 25 | 26 | 27 | no 28 | 29 | ] -------------------------------------------------------------------------------- /app/scripts/controllers/welcome.js: -------------------------------------------------------------------------------- 1 | // Generated by CoffeeScript 1.7.1 2 | "use strict"; 3 | Mifan.controller("welcomeCtrl", [ 4 | "$scope", function($scope) { 5 | $scope.$on("$viewContentLoaded", function() { 6 | return $scope.$emit("pageChange", "welcome"); 7 | }); 8 | $scope.$watch("email + password", function() { 9 | return $scope.isLoginValid = $scope.email && $scope.password; 10 | }); 11 | $scope.isLoginBox = false; 12 | $scope.isLoging = false; 13 | $scope.isReging = false; 14 | $scope.toggleLogin = function() { 15 | return $scope.isLoginBox = !$scope.isLoginBox; 16 | }; 17 | $scope.loginSubmit = function() { 18 | return $scope.isLoging = true; 19 | }; 20 | $scope.regSubmit = function() { 21 | return $scope.isReging = true; 22 | }; 23 | return false; 24 | } 25 | ]); 26 | -------------------------------------------------------------------------------- /app/scripts/defines/README.md: -------------------------------------------------------------------------------- 1 | 这个文件夹已经用不到。 2 | 3 | 本意是定义一些常量,现在这些定义放到`controllers/global.coffee`中,既然用了angular,就使用angular风格。 -------------------------------------------------------------------------------- /app/scripts/defines/constant.coffee: -------------------------------------------------------------------------------- 1 | DOC = document 2 | WIN = window 3 | LOC = location 4 | BODY = DOC['body'] 5 | 6 | ### 7 | 设备是否支持触摸事件 8 | 这里使用WIN.hasOwnProperty('ontouchend')在Android上会得到错误的结果 9 | @type {boolean} 10 | ### 11 | IsTouch = "ontouchend" of WIN 12 | 13 | NA = WIN.navigator 14 | 15 | UA = NA.userAgent 16 | 17 | # HTC Flyer平板的UA字符串中不包含Android关键词 18 | IsAndroid = (/Android|HTC/i.test(UA) or /Linux/i.test(NA.platform + "")) 19 | IsAndroidPad = IsAndroid and /Pad/i.test(UA) 20 | 21 | IsIPad = not IsAndroid and /iPad/i.test(UA) 22 | 23 | IsIPhone = not IsAndroid and /iPod|iPhone/i.test(UA) 24 | 25 | IsIOS = IsIPad or IsIPhone 26 | 27 | IsWindowsPhone = /Windows Phone/i.test(UA) 28 | 29 | IsBlackBerry = /BB10|BlackBerry/i.test(UA) 30 | 31 | IsIEMobile = /IEMobile/i.test(UA) 32 | IsIE = !!DOC.all 33 | IsWeixin = /MicroMessenger/i.test(UA) 34 | IsChrome = !!WIN['chrome'] 35 | 36 | IsPhone = IsIPhone or (IsAndroid and not IsAndroidPad) 37 | 38 | IsWebapp = !!NA["standalone"] 39 | 40 | NG = WIN['angular'] 41 | 42 | IsDebug = LOC["port"] is "9000" -------------------------------------------------------------------------------- /app/scripts/defines/constant.js: -------------------------------------------------------------------------------- 1 | // Generated by CoffeeScript 1.7.1 2 | var BODY, DOC, IsAndroid, IsAndroidPad, IsBlackBerry, IsChrome, IsDebug, IsIE, IsIEMobile, IsIOS, IsIPad, IsIPhone, IsPhone, IsTouch, IsWebapp, IsWeixin, IsWindowsPhone, LOC, NA, NG, UA, WIN; 3 | 4 | DOC = document; 5 | 6 | WIN = window; 7 | 8 | LOC = location; 9 | 10 | BODY = DOC['body']; 11 | 12 | 13 | /* 14 | 设备是否支持触摸事件 15 | 这里使用WIN.hasOwnProperty('ontouchend')在Android上会得到错误的结果 16 | @type {boolean} 17 | */ 18 | 19 | IsTouch = "ontouchend" in WIN; 20 | 21 | NA = WIN.navigator; 22 | 23 | UA = NA.userAgent; 24 | 25 | IsAndroid = /Android|HTC/i.test(UA) || /Linux/i.test(NA.platform + ""); 26 | 27 | IsAndroidPad = IsAndroid && /Pad/i.test(UA); 28 | 29 | IsIPad = !IsAndroid && /iPad/i.test(UA); 30 | 31 | IsIPhone = !IsAndroid && /iPod|iPhone/i.test(UA); 32 | 33 | IsIOS = IsIPad || IsIPhone; 34 | 35 | IsWindowsPhone = /Windows Phone/i.test(UA); 36 | 37 | IsBlackBerry = /BB10|BlackBerry/i.test(UA); 38 | 39 | IsIEMobile = /IEMobile/i.test(UA); 40 | 41 | IsIE = !!DOC.all; 42 | 43 | IsWeixin = /MicroMessenger/i.test(UA); 44 | 45 | IsChrome = !!WIN['chrome']; 46 | 47 | IsPhone = IsIPhone || (IsAndroid && !IsAndroidPad); 48 | 49 | IsWebapp = !!NA["standalone"]; 50 | 51 | NG = WIN['angular']; 52 | 53 | IsDebug = LOC["port"] === "9000"; 54 | -------------------------------------------------------------------------------- /app/scripts/defines/mifan.coffee: -------------------------------------------------------------------------------- 1 | DEFAULT_FACE = "http://mifan.us/public/images/user_large.jpg" -------------------------------------------------------------------------------- /app/scripts/defines/mifan.js: -------------------------------------------------------------------------------- 1 | // Generated by CoffeeScript 1.7.1 2 | var DEFAULT_FACE; 3 | 4 | DEFAULT_FACE = "http://mifan.us/public/images/user_large.jpg"; 5 | -------------------------------------------------------------------------------- /app/scripts/directives/custom_tag.coffee: -------------------------------------------------------------------------------- 1 | ### 2 | 自定义标签 3 | ### 4 | 5 | #加载更多 6 | Mifan.directive "more", -> 7 | 8 | templateUrl: "views/template/more.html" 9 | replace: yes 10 | restrict: "AE" 11 | 12 | #社交网络登录 13 | Mifan.directive "snslogin", -> 14 | 15 | templateUrl: "views/template/sns-login.html" 16 | replace: yes 17 | restrict: "AE" 18 | 19 | #用户相关菜单 20 | Mifan.directive "usermenu", -> 21 | 22 | priority: 0 23 | templateUrl: "views/template/usermenu.html" 24 | replace: yes 25 | restrict: "E" 26 | scope: no 27 | 28 | Mifan.directive "sending-btn", -> 29 | 30 | priority: 0 31 | templateUrl: "views/template/sending-btn.html" 32 | transclude: yes 33 | restrict: "E" 34 | scope: no 35 | 36 | Mifan.directive "logintip", -> 37 | 38 | templateUrl: "views/template/logintip.html" 39 | replace: yes 40 | restrict: "AE" 41 | scope: no 42 | 43 | Mifan.directive "errormsg", -> 44 | 45 | templateUrl: "views/template/error-msg.html" 46 | replace: yes 47 | restrict: "AE" 48 | scope: no 49 | 50 | Mifan.directive "uiloading", -> 51 | 52 | templateUrl: "views/template/ui-loading.html" 53 | replace: yes 54 | restrict: "AE" 55 | scope: no 56 | 57 | Mifan.directive "btnloading", -> 58 | 59 | template: "" 60 | replace: yes 61 | restrict: "AE" 62 | scope: no 63 | 64 | #用户冒泡弹出菜单 65 | # Mifan.directive "mbubble", -> 66 | 67 | # priority: 0 68 | # templateUrl: "views/mobile/bubble.html" 69 | # replace: yes 70 | # restrict: "E" 71 | 72 | -------------------------------------------------------------------------------- /app/scripts/directives/expander.coffee: -------------------------------------------------------------------------------- 1 | # 手风琴 2 | # 展开一项,确保整个页面只有这一个展开 3 | 4 | # Mifan.directive "accordion", -> 5 | # restrict: "EA" 6 | # controller: ($scope) -> 7 | 8 | # $scope.expanders = expanders = [] 9 | 10 | # this.gotOpened = (selectedExpander) -> 11 | # angular.forEach expanders, (expander) -> 12 | # expander.active = no if selectedExpander isnt expander 13 | 14 | # this.addExpander = (expander) -> 15 | # expanders.push expander 16 | 17 | 18 | Mifan.directive "expander", -> 19 | restrict: "EA" 20 | #require: "" 21 | #transclude: yes 22 | scope: {} 23 | link: (scope, element, attrs, ctrl) -> 24 | 25 | element.on "click", -> 26 | -------------------------------------------------------------------------------- /app/scripts/directives/expander.js: -------------------------------------------------------------------------------- 1 | // Generated by CoffeeScript 1.7.1 2 | Mifan.directive("expander", function() { 3 | return { 4 | restrict: "EA", 5 | scope: {}, 6 | link: function(scope, element, attrs, ctrl) { 7 | return element.on("click", function() {}); 8 | } 9 | }; 10 | }); 11 | -------------------------------------------------------------------------------- /app/scripts/directives/ngBlur.js: -------------------------------------------------------------------------------- 1 | Mifan.directive('ngBlur', function() { 2 | return { 3 | restrict: 'A', 4 | link: function(scope, element, attrs) { 5 | angular.element(element).bind('blur', function() { 6 | scope.$apply(attrs.ngBlur); 7 | }); 8 | } 9 | }; 10 | }); -------------------------------------------------------------------------------- /app/scripts/directives/scroller.coffee: -------------------------------------------------------------------------------- 1 | ( (window, angular) -> 2 | 3 | ### 4 | angualr 指令 5 | 轮播器 6 | 支持mobile and pc 7 | ### 8 | 9 | 'use strict' 10 | 11 | DOC = document 12 | WIN = window 13 | UNDEFINED = undefined 14 | IsTouch = 'ontouchstart' of WIN 15 | UA = WIN.navigator.userAgent 16 | IsAndroid = (/Android|HTC/i.test(UA) or !!(WIN.navigator["platform"] + "").match(/Linux/i)) 17 | 18 | START_EVENT = if IsTouch then 'touchstart' else 'mousedown' 19 | MOVE_EVENT = if IsTouch then 'touchmove' else 'mousemove' 20 | END_EVENT = if IsTouch then 'touchend' else 'mouseup' 21 | 22 | ngScorller = angular.module "binnng.scroller", [] 23 | 24 | #ngScorller.directive "scroller", -> 25 | 26 | 27 | 28 | ) window, angular -------------------------------------------------------------------------------- /app/scripts/directives/scroller.js: -------------------------------------------------------------------------------- 1 | // Generated by CoffeeScript 1.7.1 2 | (function(window, angular) { 3 | 4 | /* 5 | angualr 指令 6 | 轮播器 7 | 支持mobile and pc 8 | */ 9 | 'use strict'; 10 | var DOC, END_EVENT, IsAndroid, IsTouch, MOVE_EVENT, START_EVENT, UA, UNDEFINED, WIN, ngScorller; 11 | DOC = document; 12 | WIN = window; 13 | UNDEFINED = void 0; 14 | IsTouch = 'ontouchstart' in WIN; 15 | UA = WIN.navigator.userAgent; 16 | IsAndroid = /Android|HTC/i.test(UA) || !!(WIN.navigator["platform"] + "").match(/Linux/i); 17 | START_EVENT = IsTouch ? 'touchstart' : 'mousedown'; 18 | MOVE_EVENT = IsTouch ? 'touchmove' : 'mousemove'; 19 | END_EVENT = IsTouch ? 'touchend' : 'mouseup'; 20 | return ngScorller = angular.module("binnng.scroller", []); 21 | })(window, angular); 22 | -------------------------------------------------------------------------------- /app/scripts/directives/sub_nav.coffee: -------------------------------------------------------------------------------- 1 | # 二级导航 2 | Mifan.directive "subNav", -> 3 | templateUrl: "views/template/sub-nav.html" 4 | replace: no 5 | transclude: yes 6 | restrict: "AE" 7 | scope: no 8 | 9 | # compile: (element, attrs, transclude) -> 10 | 11 | # post: (scope, element, attrs) -> 12 | 13 | # wrapEle = element[0] 14 | # ul = wrapEle.getElementsByTagName("ul")[0] 15 | # items = ul.getElementsByTagName("li") 16 | # caret = wrapEle.getElementsByTagName("em")[0] 17 | 18 | # length = items.length 19 | 20 | # caret.style.left = "0px"; 21 | 22 | # for ele in items 23 | # ele.style.width = "#{100/length}%" 24 | -------------------------------------------------------------------------------- /app/scripts/directives/sub_nav.js: -------------------------------------------------------------------------------- 1 | // Generated by CoffeeScript 1.7.1 2 | Mifan.directive("subNav", function() { 3 | return { 4 | templateUrl: "views/template/sub-nav.html", 5 | replace: false, 6 | transclude: true, 7 | restrict: "AE", 8 | scope: false 9 | }; 10 | }); 11 | -------------------------------------------------------------------------------- /app/scripts/directives/tap.coffee: -------------------------------------------------------------------------------- 1 | ( (window, angular) -> 2 | 3 | ### 4 | angualr 指令 5 | 手指轻碰一下就会触发事件 6 | ### 7 | 8 | 'use strict' 9 | 10 | tap = angular.module 'binnng.tap', [] 11 | 12 | WIN = window 13 | IsTouch = "ontouchend" of WIN 14 | 15 | # 如果不是移动设备,什么都不做 16 | return no if not IsTouch 17 | 18 | LOC = location 19 | NA = WIN.navigator 20 | UA = NA.userAgent 21 | 22 | #IsAndroid = (/Android|HTC/i.test(UA) or /Linux/i.test(NA.platform + "")) 23 | 24 | tap.directive "tap", -> 25 | 26 | link: (scope, element, attrs) -> 27 | 28 | fnName = attrs["tap"].replace "()", "" 29 | fn = scope[fnName] 30 | 31 | return no if not fn 32 | 33 | element.on "touchstart", (event) -> 34 | fn() 35 | event.stopPropagation() 36 | 37 | ) window, angular 38 | -------------------------------------------------------------------------------- /app/scripts/directives/tap.js: -------------------------------------------------------------------------------- 1 | // Generated by CoffeeScript 1.7.1 2 | (function(window, angular) { 3 | 4 | /* 5 | angualr 指令 6 | 手指轻碰一下就会触发事件 7 | */ 8 | 'use strict'; 9 | var IsTouch, LOC, NA, UA, WIN, tap; 10 | tap = angular.module('binnng.tap', []); 11 | WIN = window; 12 | IsTouch = "ontouchend" in WIN; 13 | if (!IsTouch) { 14 | return false; 15 | } 16 | LOC = location; 17 | NA = WIN.navigator; 18 | UA = NA.userAgent; 19 | return tap.directive("tap", function() { 20 | return { 21 | link: function(scope, element, attrs) { 22 | var fn, fnName; 23 | fnName = attrs["tap"].replace("()", ""); 24 | fn = scope[fnName]; 25 | if (!fn) { 26 | return false; 27 | } 28 | return element.on("touchstart", function(event) { 29 | fn(); 30 | return event.stopPropagation(); 31 | }); 32 | } 33 | }; 34 | }); 35 | })(window, angular); 36 | -------------------------------------------------------------------------------- /app/scripts/filters.js: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/app/scripts/filters.js -------------------------------------------------------------------------------- /app/scripts/services/extend.coffee: -------------------------------------------------------------------------------- 1 | # 复制一个Object属性到另一个 2 | # author: binnng 3 | 4 | ((window, angular) -> 5 | 6 | extend = (src, dist) -> 7 | src[name] = dist[name] for name of dist 8 | src 9 | 10 | (angular.module "binnng.extend", []).factory "$extend", -> 11 | extend 12 | 13 | 14 | ) window, angular 15 | -------------------------------------------------------------------------------- /app/scripts/services/extend.js: -------------------------------------------------------------------------------- 1 | // Generated by CoffeeScript 1.7.1 2 | (function(window, angular) { 3 | var extend; 4 | extend = function(src, dist) { 5 | var name; 6 | for (name in dist) { 7 | src[name] = dist[name]; 8 | } 9 | return src; 10 | }; 11 | return (angular.module("binnng.extend", [])).factory("$extend", function() { 12 | return extend; 13 | }); 14 | })(window, angular); 15 | -------------------------------------------------------------------------------- /app/scripts/services/random.coffee: -------------------------------------------------------------------------------- 1 | # 取一个区间的随机数 2 | # author: binnng 3 | 4 | ((window, angular) -> 5 | 6 | M = Math 7 | 8 | random = M.random 9 | 10 | random.in = (array) -> 11 | len = array.length 12 | 13 | min = array[0] 14 | max = array[len - 1] 15 | 16 | M.floor(min + random() * (max - min)) 17 | 18 | (angular.module "binnng/random", []).factory "$random", -> 19 | random 20 | 21 | 22 | ) window, angular 23 | -------------------------------------------------------------------------------- /app/scripts/services/random.js: -------------------------------------------------------------------------------- 1 | // Generated by CoffeeScript 1.7.1 2 | (function(window, angular) { 3 | var M, random; 4 | M = Math; 5 | random = M.random; 6 | random["in"] = function(array) { 7 | var len, max, min; 8 | len = array.length; 9 | min = array[0]; 10 | max = array[len - 1]; 11 | return M.floor(min + random() * (max - min)); 12 | }; 13 | return (angular.module("binnng/random", [])).factory("$random", function() { 14 | return random; 15 | }); 16 | })(window, angular); 17 | -------------------------------------------------------------------------------- /app/scripts/services/storage.coffee: -------------------------------------------------------------------------------- 1 | ((window, angular) -> 2 | 3 | # 对本地存贮对象的操作封装 4 | 5 | WIN = window 6 | 7 | Storage = angular.module "binnng.storage", [] 8 | 9 | getStorage = -> 10 | _localStorage = undefined 11 | try 12 | 13 | # 在Android 4.0下,如果webview没有打开localStorage支持 14 | # 在读取localStorage对象的时候会导致js运行出错,所以要放在try{}catch{}中 15 | 16 | _localStorage = WIN["localStorage"] 17 | catch e 18 | alert "localStorage is not supported" 19 | 20 | getStorage = -> 21 | WIN["localStorage"] 22 | 23 | _localStorage 24 | 25 | storage = getStorage() 26 | 27 | Storage.factory "$storage", -> 28 | 29 | set: (key, value) -> 30 | if storage 31 | storage.setItem key, value 32 | 33 | get: (key) -> 34 | if storage 35 | value = storage.getItem(key) 36 | 37 | # 清除本地存贮数据 38 | # key 可选,如果包含此参数,则只删除包含此前缀的项,否则清除全部缓存 39 | 40 | clear: (key) -> 41 | if storage 42 | if key 43 | for key of storage 44 | storage.removeItem key if 0 is key.indexOf(key) 45 | else 46 | storage.clear() 47 | 48 | 49 | 50 | ) window, angular -------------------------------------------------------------------------------- /app/scripts/services/storage.js: -------------------------------------------------------------------------------- 1 | // Generated by CoffeeScript 1.7.1 2 | (function(window, angular) { 3 | var Storage, WIN, getStorage, storage; 4 | WIN = window; 5 | Storage = angular.module("binnng.storage", []); 6 | getStorage = function() { 7 | var e, _localStorage; 8 | _localStorage = void 0; 9 | try { 10 | _localStorage = WIN["localStorage"]; 11 | } catch (_error) { 12 | e = _error; 13 | alert("localStorage is not supported"); 14 | } 15 | getStorage = function() { 16 | return WIN["localStorage"]; 17 | }; 18 | return _localStorage; 19 | }; 20 | storage = getStorage(); 21 | return Storage.factory("$storage", function() { 22 | return { 23 | set: function(key, value) { 24 | if (storage) { 25 | return storage.setItem(key, value); 26 | } 27 | }, 28 | get: function(key) { 29 | var value; 30 | if (storage) { 31 | return value = storage.getItem(key); 32 | } 33 | }, 34 | clear: function(key) { 35 | var _results; 36 | if (storage) { 37 | if (key) { 38 | _results = []; 39 | for (key in storage) { 40 | if (0 === key.indexOf(key)) { 41 | _results.push(storage.removeItem(key)); 42 | } else { 43 | _results.push(void 0); 44 | } 45 | } 46 | return _results; 47 | } else { 48 | return storage.clear(); 49 | } 50 | } 51 | } 52 | }; 53 | }); 54 | })(window, angular); 55 | -------------------------------------------------------------------------------- /app/styles/imports/404.scss: -------------------------------------------------------------------------------- 1 | .page-404 { 2 | max-width: 400px; 3 | _width: 400px; 4 | padding: 30px 20px 50px; 5 | margin: 0 auto; 6 | 7 | h1 { 8 | margin: 0 10px; 9 | font-size: 10em; 10 | text-align: center; 11 | } 12 | 13 | h1 span { 14 | color: #bbb; 15 | } 16 | 17 | h3 { 18 | margin: 1.5em 0 0.5em; 19 | } 20 | 21 | } -------------------------------------------------------------------------------- /app/styles/imports/about.scss: -------------------------------------------------------------------------------- 1 | .about-page{ 2 | 3 | .main{ 4 | padding: 2em; 5 | padding-bottom: 6em; 6 | 7 | } 8 | h3{ 9 | margin-bottom: 1em; 10 | } 11 | 12 | .site-intro{ 13 | line-height: 2; 14 | } 15 | } -------------------------------------------------------------------------------- /app/styles/imports/define/color.scss: -------------------------------------------------------------------------------- 1 | 2 | $tone-color: #3d96dc; 3 | $tone: $tone-color; 4 | $black: #11171c; 5 | $light-black: #23282c; 6 | $white: #fff; 7 | $gray: #999; 8 | 9 | $green: #5cb85c; 10 | 11 | $error-color: #d9534f; 12 | $link-color: #2a6496; 13 | 14 | $bg: $white; 15 | 16 | $root-bg: #1e1e1e; 17 | 18 | $dark-tone: darken($tone, 10%); 19 | 20 | $light-gray: #ddd; 21 | $dark-gray: darken($gray, 40%); 22 | 23 | $red: red; 24 | 25 | $cardBg: #fefefe; 26 | $cardBg: $white; 27 | 28 | 29 | 30 | $primary: #0074cc; 31 | $danger: #da4f49; 32 | $warn: #faa732; 33 | $success: #5bb75b; 34 | $error: #bd362f; -------------------------------------------------------------------------------- /app/styles/imports/define/screen.scss: -------------------------------------------------------------------------------- 1 | $screen-xs: 480px !default; 2 | //** Deprecated `$screen-xs-min` as of v3.2.0 3 | $screen-xs-min: $screen-xs !default; 4 | //** Deprecated `$screen-phone` as of v3.0.1 5 | $screen-phone: $screen-xs-min !default; 6 | 7 | // Small screen / tablet 8 | //** Deprecated `$screen-sm` as of v3.0.1 9 | $screen-sm: 768px !default; 10 | $screen-sm-min: $screen-sm !default; 11 | //** Deprecated `$screen-tablet` as of v3.0.1 12 | $screen-tablet: $screen-sm-min !default; 13 | 14 | // Medium screen / desktop 15 | //** Deprecated `$screen-md` as of v3.0.1 16 | $screen-md: 992px !default; 17 | $screen-md-min: $screen-md !default; 18 | //** Deprecated `$screen-desktop` as of v3.0.1 19 | $screen-desktop: $screen-md-min !default; 20 | 21 | // Large screen / wide desktop 22 | //** Deprecated `$screen-lg` as of v3.0.1 23 | $screen-lg: 1200px !default; 24 | $screen-lg-min: $screen-lg !default; 25 | //** Deprecated `$screen-lg-desktop` as of v3.0.1 26 | $screen-lg-desktop: $screen-lg-min !default; 27 | 28 | // So media queries don't overlap when required, provide a maximum 29 | $screen-xs-max: ($screen-sm-min - 1) !default; 30 | $screen-sm-max: ($screen-md-min - 1) !default; 31 | $screen-md-max: ($screen-lg-min - 1) !default; 32 | -------------------------------------------------------------------------------- /app/styles/imports/foot.scss: -------------------------------------------------------------------------------- 1 | .footer { 2 | margin-top: 26px; 3 | padding: 80px 0; 4 | color: #777; 5 | border-top: 1px solid #e5e5e5; 6 | background-color: $white; 7 | p{ 8 | text-align: center; 9 | a{ 10 | color: #777; 11 | &:hover{ 12 | color: $tone; 13 | } 14 | } 15 | 16 | .loved{ 17 | //color: red; 18 | } 19 | } 20 | } 21 | 22 | @media (max-width: $screen-xs-max) { 23 | .footer{ 24 | padding: 10px 0; 25 | } 26 | } -------------------------------------------------------------------------------- /app/styles/imports/friend/friend.scss: -------------------------------------------------------------------------------- 1 | .friend-page{ 2 | .sub-nav-wrap{ 3 | margin-top: .6em; 4 | } 5 | } -------------------------------------------------------------------------------- /app/styles/imports/functions.scss: -------------------------------------------------------------------------------- 1 | 2 | @function black($opacity){ 3 | @return rgba(0,0,0,$opacity) 4 | } 5 | @function white($opacity){ 6 | @return rgba(255,255,255,$opacity) 7 | } -------------------------------------------------------------------------------- /app/styles/imports/high-pixel-ratio.scss: -------------------------------------------------------------------------------- 1 | // 高清屏 2 | @media only screen and (-webkit-min-device-pixel-ratio: 1.3) { 3 | 4 | .logo{ 5 | background-image: url(../images/logo@2x.png); 6 | } 7 | } -------------------------------------------------------------------------------- /app/styles/imports/home/side.scss: -------------------------------------------------------------------------------- 1 | .home-page{ 2 | 3 | .every-day-ask{ 4 | color: #555; 5 | .ans-num{ 6 | width: 60px; 7 | height: 60px; 8 | background-color: $tone; 9 | box-shadow: inset 0 0 2px rgba(0, 0, 0, .1); 10 | color: #fff; 11 | margin-right: 1em; 12 | border-radius: 2px; 13 | span, 14 | b{ 15 | display: block; 16 | line-height: 2; 17 | text-align: center; 18 | } 19 | b{ 20 | font-size: 1.2em; 21 | } 22 | } 23 | .content{ 24 | color: #555; 25 | display: block; 26 | overflow: hidden; 27 | text-align: justify; 28 | &:hover, 29 | &:active{ 30 | color: #111; 31 | } 32 | } 33 | } 34 | 35 | 36 | .invite{ 37 | box-shadow: inset 0 1px 6px 0 rgba(0,0,0,0.05), 38 | inset 1px 0px 6px 0 rgba(0,0,0,0.05), 39 | inset 0 -1px 6px 0 rgba(0,0,0,0.05), 40 | inset -1px 0 6px 0 rgba(0,0,0,0.05); 41 | 42 | padding: 10px; 43 | border: 1px solid $light-gray; 44 | border-radius: 3px; 45 | p{ 46 | margin: 0; 47 | } 48 | } 49 | 50 | } 51 | 52 | 53 | 54 | //pad 55 | @media (max-width: $screen-sm-max) and (min-width: $screen-xs-max) { 56 | .home-page{ 57 | 58 | .every-day-ask{ 59 | .ans-num{ 60 | float: none !important; 61 | display: block; 62 | width: 100%; 63 | text-align: center; 64 | line-height: 40px; 65 | height: auto; 66 | margin-bottom: 1em; 67 | span, 68 | b{ 69 | display: inline; 70 | } 71 | } 72 | } 73 | } 74 | } 75 | -------------------------------------------------------------------------------- /app/styles/imports/ipad.scss: -------------------------------------------------------------------------------- 1 | // iPad 2 | 3 | .ipad{ 4 | // 开关 5 | // .switch .item{ 6 | // font-size: 1.1em; 7 | // padding: .4em 1em; 8 | // background-color: $light-gray; 9 | // color: $dark-gray; 10 | // border: 1px solid $gray; 11 | // &:active, 12 | // &.active{ 13 | // color: $tone; 14 | // box-shadow: inset 0 1px 3px rgba(0, 0, 0, .2); 15 | // } 16 | 17 | // &:first-child{ 18 | // border-radius: 2px 0 0 2px; 19 | // border-right: none; 20 | // } 21 | 22 | // &:last-child{ 23 | // border-radius: 0 2px 2px 0; 24 | // &:before{ 25 | // display: none; 26 | // } 27 | // } 28 | // } 29 | 30 | 31 | // .header{ 32 | // .login{ 33 | // line-height: 30px; 34 | // margin-top: 10px; 35 | // margin-bottom: 10px; 36 | // .switch{ 37 | // .item{ 38 | // padding-top: 0; 39 | // padding-bottom: 0; 40 | // color: #428bca; 41 | // &:hover{ 42 | // color: #2a6496; 43 | // } 44 | // &.active{ 45 | // color: $gray; 46 | // } 47 | // } 48 | // } 49 | // } 50 | // } 51 | 52 | } -------------------------------------------------------------------------------- /app/styles/imports/me.scss: -------------------------------------------------------------------------------- 1 | .me-page{ 2 | .main{ 3 | 4 | } 5 | 6 | .sub-nav-wrap{ 7 | margin-top: 0; 8 | } 9 | .side{ 10 | padding: 0; 11 | } 12 | } 13 | 14 | 15 | 16 | 17 | // phone 18 | @media (max-width: $screen-xs-max) { 19 | 20 | .me-page{ 21 | 22 | .sub-nav-wrap{ 23 | margin-top: 10px; 24 | } 25 | .sub-nav{ 26 | li{ 27 | width: 33.3333%; 28 | } 29 | } 30 | 31 | .side{ 32 | margin: 0; 33 | padding: 0; 34 | } 35 | } 36 | } 37 | -------------------------------------------------------------------------------- /app/styles/imports/mixins.scss: -------------------------------------------------------------------------------- 1 | @mixin background-linear-gradient($value...) { 2 | background-image: -webkit-linear-gradient($value...); 3 | background-image: -moz-linear-gradient($value...); 4 | background-image: -ms-linear-gradient($value...); 5 | background-image: -o-linear-gradient($value...); 6 | background-image: linear-gradient($value...); 7 | } 8 | 9 | @mixin ellipsis { 10 | overflow: hidden; 11 | text-overflow: ellipsis; 12 | white-space: nowrap; 13 | display: inline-block; 14 | } 15 | -------------------------------------------------------------------------------- /app/styles/imports/module/answer-form-mod.scss: -------------------------------------------------------------------------------- 1 | 2 | .ans-form-mod{ 3 | .ans-input{ 4 | padding: .2em .6em; 5 | //box-shadow: 0px 1px 1px 0px #eaeaea inset; 6 | border: 1px solid #ccc; 7 | display: block; 8 | width: 100%; 9 | border-radius: 2px; 10 | height: 2.2em; 11 | @include transition(all, .2s); 12 | 13 | &.active{ 14 | height: 4em; 15 | } 16 | } 17 | .btn{ 18 | font-size: .9em; 19 | float: right; 20 | margin-top: .8em; 21 | padding-left: 1.6em; 22 | padding-right: 1.6em; 23 | } 24 | } -------------------------------------------------------------------------------- /app/styles/imports/module/face.scss: -------------------------------------------------------------------------------- 1 | 2 | // 头像 3 | .face, 4 | .avatar{ 5 | background-size: cover; 6 | background-repeat: no-repeat; 7 | border-radius: 999px; 8 | background-color: $light-gray; 9 | display: inline-block; 10 | text-indent: -999em; 11 | } 12 | .face-20{ 13 | width: 20px; 14 | height: 20px; 15 | } 16 | 17 | .face-30{ 18 | width: 30px; 19 | height: 30px; 20 | } 21 | 22 | .face-42{ 23 | width: 42px; 24 | height: 42px; 25 | } 26 | .face-50{ 27 | width: 50px; 28 | height: 50px; 29 | } 30 | .face-136{ 31 | width: 136px; 32 | height: 136px; 33 | } 34 | 35 | // scroller 36 | 37 | .scroller-wrap{ 38 | //width: 100%; 39 | overflow-x: hidden; 40 | 41 | .scroller{ 42 | width: 8000px; 43 | 44 | } 45 | } -------------------------------------------------------------------------------- /app/styles/imports/module/feed-actions.scss: -------------------------------------------------------------------------------- 1 | 2 | .feed-actions-mod{ 3 | padding: 14px 0 0; 4 | position: relative; 5 | height: 38px; 6 | 7 | .act-left{ 8 | //margin-top: 12px; 9 | } 10 | 11 | .m-bubble{ 12 | position: absolute; 13 | right: 0; 14 | } 15 | 16 | a,b{ 17 | &:hover{ 18 | color: $dark-gray; 19 | } 20 | &:active{ 21 | color: $tone; 22 | } 23 | } 24 | 25 | .like, 26 | .m-cmt, 27 | .cmt-tgl-btn{ 28 | color: $gray; 29 | cursor: pointer; 30 | padding: 0 .6em; 31 | font-weight: 400; 32 | .glyphicon-heart{ 33 | margin-right: .2em; 34 | } 35 | .count{ 36 | vertical-align: bottom; 37 | } 38 | } 39 | 40 | .like{ 41 | padding-right: 2px; 42 | &.loved{ 43 | .glyphicon-heart{ 44 | color: $red; 45 | } 46 | cursor: auto; 47 | &:hover{ 48 | color: $gray; 49 | } 50 | } 51 | } 52 | 53 | .m-cmt{ 54 | .glyphicon-comment{ 55 | margin-right: .24em; 56 | } 57 | } 58 | 59 | .bill-btn{ 60 | 61 | } 62 | 63 | .liked-list{ 64 | margin-left: .2em; 65 | overflow: hidden; 66 | li{ 67 | float: left; 68 | margin-right: 4px; 69 | } 70 | .avatar{ 71 | width: 20px; 72 | height: 20px; 73 | margin: 0; 74 | } 75 | } 76 | } -------------------------------------------------------------------------------- /app/styles/imports/module/load-more.scss: -------------------------------------------------------------------------------- 1 | 2 | 3 | // 加载更多 4 | .load-more{ 5 | text-align: center; 6 | padding: 18px; 7 | color: $tone; 8 | cursor: pointer; 9 | font-size: 1em; 10 | position: relative; 11 | margin-top: 12px; 12 | &:hover, 13 | &:active{ 14 | background-color: $light-gray; 15 | } 16 | &.loading{ 17 | cursor: auto; 18 | &:hover, 19 | &:active{ 20 | background-color: transparent; 21 | } 22 | } 23 | } 24 | 25 | // .loading-tip i, 26 | // .loading-tip:after, 27 | // .loading-tip:before{ 28 | // content: ""; 29 | // width: 4px; 30 | // height: 4px; 31 | // background-color: $tone; 32 | // display: inline-block; 33 | // margin-right: 2px; 34 | // } -------------------------------------------------------------------------------- /app/styles/imports/module/login-tip.scss: -------------------------------------------------------------------------------- 1 | .nologin-tip{ 2 | text-align: center; 3 | a{ 4 | color: #fff; 5 | } 6 | i{ 7 | margin-right: 6px; 8 | } 9 | } -------------------------------------------------------------------------------- /app/styles/imports/module/page.scss: -------------------------------------------------------------------------------- 1 | .page-mod{ 2 | 3 | .main{ 4 | 5 | max-width: 600px; 6 | margin: 0 auto; 7 | 8 | padding: 8px; 9 | 10 | } 11 | 12 | 13 | .side{ 14 | background-color: $cardBg; 15 | padding: 14px 18px; 16 | margin-left: 3em; 17 | max-width: 300px; 18 | margin: 0 auto; 19 | .side-mod{ 20 | margin-bottom: 2em; 21 | overflow: hidden; 22 | h5{ 23 | .icon{ 24 | float: right; 25 | cursor: pointer; 26 | } 27 | } 28 | } 29 | } 30 | 31 | } 32 | 33 | 34 | @media (max-width: $screen-md-max) and (min-width: $screen-sm-max) { 35 | .page-mod{ 36 | .side{ 37 | margin-left: 1.8em; 38 | } 39 | } 40 | } 41 | 42 | //pad 43 | @media (max-width: $screen-sm-max) and (min-width: $screen-xs-max) { 44 | .page-mod{ 45 | .side{ 46 | margin-left: .6em; 47 | } 48 | } 49 | } 50 | 51 | 52 | //phone 53 | 54 | @media (max-width: $screen-xs-max) { 55 | .page-mod{ 56 | 57 | .main{ 58 | max-width: none; 59 | } 60 | 61 | .side{ 62 | margin-top: 2em; 63 | max-width: none; 64 | } 65 | 66 | 67 | } 68 | } -------------------------------------------------------------------------------- /app/styles/imports/module/pagination.scss: -------------------------------------------------------------------------------- 1 | .pagination-nav{ 2 | text-align: center; 3 | 4 | li{ 5 | position: relative; 6 | } 7 | 8 | .glyphicon{ 9 | position: absolute; 10 | top: 9px; 11 | right: 8px; 12 | } 13 | 14 | .unsee{ 15 | visibility: hidden; 16 | } 17 | } -------------------------------------------------------------------------------- /app/styles/imports/module/profile.scss: -------------------------------------------------------------------------------- 1 | .profile{ 2 | 3 | .blk{ 4 | margin-top: .8em; 5 | } 6 | .blk-sep{ 7 | border-top: 1px dashed rgba(#000, .1); 8 | display: block; 9 | margin: 18px 0; 10 | } 11 | .cover{ 12 | height: 145px; 13 | background-size: cover; 14 | background-position: center center; 15 | } 16 | 17 | .face{ 18 | margin: -100px auto 10px; 19 | display: block; 20 | border: 6px #fefefe solid; 21 | } 22 | 23 | .bio{ 24 | text-align: center; 25 | padding: 0 1em 1em; 26 | } 27 | 28 | .username{ 29 | display: block; 30 | text-align: center; 31 | font-size: 1.3em; 32 | } 33 | 34 | .intro{ 35 | color: $gray; 36 | font-size: .9em; 37 | margin-top: .4em; 38 | } 39 | 40 | .sns{ 41 | i{ 42 | margin: 0 2px -6px 0; 43 | } 44 | span{ 45 | display: inline-block; 46 | height: 25px; 47 | color: $dark-gray; 48 | font-size: .9em; 49 | margin-right: 4px; 50 | } 51 | } 52 | 53 | .fans{ 54 | font-size: .9em; 55 | span{ 56 | margin-right: .6em; 57 | } 58 | a{ 59 | font-size: 1.2em; 60 | } 61 | } 62 | 63 | .follow{ 64 | .btn{ 65 | min-width: 86px; 66 | } 67 | } 68 | 69 | .ask-him-box{ 70 | .btn{ 71 | width: 100%; 72 | margin-top: 10px; 73 | } 74 | } 75 | 76 | .addtime{ 77 | color: $gray; 78 | } 79 | 80 | 81 | } -------------------------------------------------------------------------------- /app/styles/imports/module/qa-cmt.scss: -------------------------------------------------------------------------------- 1 | .qa-cmt{ 2 | overflow: hidden; 3 | margin-top: 10px; 4 | 5 | textarea{ 6 | width: 100%; 7 | box-shadow: 0px 1px 1px 0px #eaeaea inset; 8 | border: 1px solid #ccc; 9 | } 10 | .cmt-form{ 11 | .cmt-input{ 12 | height: 4em; 13 | padding: .2em .6em; 14 | 15 | } 16 | .btn{ 17 | font-size: .9em; 18 | float: right; 19 | margin-top: .8em; 20 | } 21 | } 22 | .cmt-list{ 23 | 24 | } 25 | .cmt-item{ 26 | border-bottom: 1px solid $light-gray; 27 | padding: .5em .4em; 28 | &:last-child{ 29 | border: none; 30 | } 31 | .cmt-face{ 32 | margin-right: .8em; 33 | float: left; 34 | } 35 | .cmt-detail{ 36 | overflow: hidden; 37 | font-size: .9em; 38 | h5{ 39 | margin-top: 4px; 40 | a{ 41 | color: #555; 42 | font-weight: 400; 43 | margin-right: 1.2em; 44 | } 45 | span{ 46 | color: $gray; 47 | font-size: .9em; 48 | } 49 | } 50 | 51 | .cont-txt{ 52 | color: #555; 53 | } 54 | } 55 | .cmt-reply{ 56 | overflow: hidden; 57 | } 58 | 59 | 60 | .cmt-reply-input{ 61 | height: 2.4em; 62 | padding: .5em .6em; 63 | } 64 | 65 | .cmt-reply-btn{ 66 | float: right; 67 | font-size: .8em; 68 | margin-top: 0; 69 | padding-top: .4em; 70 | padding-bottom: .4em; 71 | overflow: hidden; 72 | .btn{ 73 | float: right; 74 | padding: 0; 75 | } 76 | } 77 | } 78 | } -------------------------------------------------------------------------------- /app/styles/imports/module/ques-ans.scss: -------------------------------------------------------------------------------- 1 | .qa-mod{ 2 | 3 | &:hover{ 4 | //background: #effaff; 5 | } 6 | 7 | .h5{ 8 | margin: 0 0 .6em 0; 9 | line-height: 1.4; 10 | font-weight: 400; 11 | a{ 12 | color: #666; 13 | &:hover{ 14 | color: #000; 15 | } 16 | } 17 | } 18 | 19 | .lead{ 20 | font-size: 1.1em; 21 | margin-bottom: 0; 22 | } 23 | 24 | 25 | &.hide-action{ 26 | .actions{ 27 | display: none; 28 | } 29 | } 30 | 31 | } 32 | 33 | @media (max-width: $screen-xs-max) { 34 | .qa-mod{ 35 | 36 | .avatars{ 37 | margin-right: .6em; 38 | .asker{ 39 | } 40 | .answerer{ 41 | margin: -10px 0 0 8px; 42 | } 43 | } 44 | } 45 | } -------------------------------------------------------------------------------- /app/styles/imports/module/ques-single-mod.scss: -------------------------------------------------------------------------------- 1 | .ques-mod{ 2 | .content{ 3 | overflow: hidden; 4 | 5 | a{ 6 | color: $black; 7 | &:hover{ 8 | color: $tone; 9 | } 10 | } 11 | .meta{ 12 | font-size: .9em; 13 | } 14 | 15 | .h5{ 16 | font-weight: 400; 17 | line-height: 1.4; 18 | font-size: 1.1em; 19 | } 20 | } 21 | .face{ 22 | float: left; 23 | margin-right: 1em; 24 | } 25 | 26 | 27 | } -------------------------------------------------------------------------------- /app/styles/imports/module/sns.scss: -------------------------------------------------------------------------------- 1 | .sns{ 2 | i, 3 | .glyphicon-refresh{ 4 | position: absolute; 5 | } 6 | i{ 7 | background-image: url(../images/icon-sns.png); 8 | background-repeat: no-repeat; 9 | background-size: 50px; 10 | width: 25px; 11 | height: 25px; 12 | } 13 | 14 | .weibo{ 15 | i{ 16 | background-position: 0 -25px; 17 | } 18 | } 19 | .qq{ 20 | } 21 | .douban{ 22 | i{ 23 | background-position: 0 -50px; 24 | } 25 | } 26 | 27 | } 28 | 29 | .sns-color{ 30 | 31 | 32 | .weibo{ 33 | i{ 34 | background-position: -25px -25px; 35 | } 36 | } 37 | .weixin{ 38 | i{ 39 | background-position: -25px -75px; 40 | } 41 | } 42 | .douban{ 43 | i{ 44 | background-position: -25px -50px; 45 | } 46 | } 47 | 48 | } 49 | 50 | // 高清屏 51 | @media only screen and (-webkit-min-device-pixel-ratio: 1.3) { 52 | .sns{ 53 | i{ 54 | background-image: url(../images/icon-sns@2x.png); 55 | } 56 | } 57 | } -------------------------------------------------------------------------------- /app/styles/imports/module/ui-loading.scss: -------------------------------------------------------------------------------- 1 | .ui-loading-wrap { 2 | position: relative; 3 | } 4 | 5 | 6 | // 加载动画 7 | .ui-loading, 8 | .ui-loading:after, 9 | .ui-loading:before { 10 | width:4px; 11 | height:4px; 12 | background: $tone; 13 | } 14 | .ui-loading { 15 | padding:0!important; 16 | opacity:1; 17 | -webkit-animation-delay:.6s; 18 | animation-delay:.6s; 19 | position: absolute; 20 | top: 50%; 21 | margin: -2px 0 0 -3px; 22 | left: 50%; 23 | } 24 | .ui-loading:after, 25 | .ui-loading:before { 26 | content:""; 27 | position:absolute 28 | } 29 | .ui-loading:after { 30 | margin-right:auto; 31 | left:-7px; 32 | -webkit-animation-delay:.3s; 33 | animation-delay:.3s; 34 | } 35 | .ui-loading:before { 36 | margin-right:auto; 37 | left:7px; 38 | -webkit-animation-delay:.9s; 39 | animation-delay:.9s; 40 | } 41 | 42 | // 标准的loading HTML结构 43 | //
加载更多
44 | .loading { 45 | > .ui-loading, 46 | > .ui-loading:after, 47 | > .ui-loading:before { 48 | //display: block; 49 | -webkit-animation:ui-loading .8s infinite linear; 50 | animation:ui-loading .8s infinite linear; 51 | } 52 | > .ui-loading:after { 53 | -webkit-animation-delay:.3s; 54 | animation-delay:.3s; 55 | } 56 | > .ui-loading:before { 57 | -webkit-animation-delay:.9s; 58 | animation-delay:.9s; 59 | } 60 | } 61 | 62 | // .loading > .loading-tip{ 63 | // visibility: hidden; 64 | // } 65 | 66 | @-webkit-keyframes ui-loading { 67 | 0%,100% { 68 | opacity:.1 69 | } 70 | 30% { 71 | opacity:1 72 | } 73 | } 74 | 75 | @keyframes ui-loading { 76 | 0%,100% { 77 | opacity:.1 78 | } 79 | 30% { 80 | opacity:1 81 | } 82 | } -------------------------------------------------------------------------------- /app/styles/imports/module/user-list.scss: -------------------------------------------------------------------------------- 1 | .user-list-mod{ 2 | 3 | li{ 4 | border-bottom: 1px dashed $light-gray; 5 | overflow: hidden; 6 | 7 | &:last-child{ 8 | border: none; 9 | } 10 | 11 | } 12 | } 13 | 14 | .flat-user-list-mod{ 15 | li{ 16 | .btn{ 17 | float: right; 18 | } 19 | } 20 | } -------------------------------------------------------------------------------- /app/styles/imports/module/user-mod.scss: -------------------------------------------------------------------------------- 1 | .user-mod{ 2 | padding: .6em .4em; 3 | .face{ 4 | float: left; 5 | margin: 4px 1.2em 2px 0; 6 | } 7 | 8 | .info{ 9 | overflow: hidden; 10 | } 11 | 12 | .username{ 13 | margin-bottom: 4px; 14 | display: block; 15 | } 16 | 17 | .btn{ 18 | padding: 4px 12px; 19 | min-width: 82px; 20 | } 21 | 22 | .brief{ 23 | margin-right: 1em; 24 | } 25 | } -------------------------------------------------------------------------------- /app/styles/imports/msg.scss: -------------------------------------------------------------------------------- 1 | .msg-page{ 2 | .main{ 3 | 4 | max-width: 600px; 5 | margin: 0 auto; 6 | padding: 10px 8px; 7 | padding-bottom: 2em; 8 | min-height: 100px; 9 | position: relative; 10 | 11 | .lead{ 12 | //background-color: $light-gray; 13 | //border-radius: 2px; 14 | font-size: .9em !important; 15 | padding: .4em 1em; 16 | margin-top: 1em; 17 | color: $gray; 18 | b{ 19 | margin: 0 .2em; 20 | } 21 | } 22 | 23 | .questions{ 24 | dd{ 25 | 26 | } 27 | } 28 | 29 | .face{ 30 | margin-right: 1em; 31 | } 32 | 33 | .ques-dtl{ 34 | overflow: hidden; 35 | .h5{ 36 | line-height: 1.4; 37 | margin: 0; 38 | font-weight: 400; 39 | color: $black; 40 | &:hover, 41 | &:active{ 42 | color: $dark-gray; 43 | } 44 | } 45 | .meta{ 46 | margin: .8em 0; 47 | } 48 | } 49 | 50 | .m-ans{ 51 | .ans-btn{ 52 | padding: 4px 1em; 53 | 54 | } 55 | } 56 | 57 | .m-acts{ 58 | position: relative; 59 | margin-bottom: 0; 60 | overflow: hidden; 61 | } 62 | } 63 | } 64 | 65 | 66 | //phone 67 | 68 | @media (max-width: $screen-xs-max) { 69 | .msg-page{ 70 | .main{ 71 | max-width: none; 72 | 73 | .questions{ 74 | dd{ 75 | .face{ 76 | width: 35px; 77 | height: 35px; 78 | } 79 | } 80 | } 81 | 82 | .ques-dtl{ 83 | 84 | .meta{ 85 | margin-bottom: -.4em; 86 | } 87 | } 88 | } 89 | } 90 | 91 | } -------------------------------------------------------------------------------- /app/styles/imports/notification.scss: -------------------------------------------------------------------------------- 1 | .notification{ 2 | 3 | } -------------------------------------------------------------------------------- /app/styles/imports/ques/ques.scss: -------------------------------------------------------------------------------- 1 | .ques-page{ 2 | .main{ 3 | max-width: 600px; 4 | margin: 0 auto; 5 | padding: 0 8px; 6 | padding-bottom: 2em; 7 | min-height: 100px; 8 | position: relative; 9 | } 10 | .ques-mod{ 11 | margin: 1.6em 0; 12 | } 13 | .ans-list{ 14 | margin-top: 2em; 15 | dd{ 16 | border-bottom: 1px $light-gray dashed; 17 | overflow: hidden; 18 | padding: 1em; 19 | margin-left: 2em; 20 | .face{ 21 | margin-right: 1em; 22 | } 23 | font-size: .9em; 24 | 25 | &:last-child{ 26 | border-bottom: none; 27 | } 28 | } 29 | .lead{ 30 | font-size: 1.1em; 31 | } 32 | .face{ 33 | float: left; 34 | } 35 | } 36 | 37 | .feed-actions-mod{ 38 | font-size: 1.1em; 39 | } 40 | } -------------------------------------------------------------------------------- /app/styles/imports/square/side.scss: -------------------------------------------------------------------------------- 1 | .square-page{ 2 | 3 | } -------------------------------------------------------------------------------- /app/styles/imports/square/square.scss: -------------------------------------------------------------------------------- 1 | .square-top{ 2 | padding: 1em; 3 | 4 | background-image: url(../images/square-bg.jpg); 5 | // this is a hack 6 | background-size: 100%; 7 | background-size: cover; 8 | background-repeat: no-repeat; 9 | 10 | h5{ 11 | //border-bottom: 1px solid $white; 12 | padding-bottom: .4em; 13 | } 14 | } 15 | 16 | -------------------------------------------------------------------------------- /app/styles/imports/toast.scss: -------------------------------------------------------------------------------- 1 | .toast{ 2 | position: fixed; 3 | right: 0; 4 | bottom: 80px; 5 | background: $tone; 6 | color: $white; 7 | z-index: 800; 8 | padding: 10px 20px; 9 | border-radius: 2px 0 0 2px; 10 | opacity: 1; 11 | @include transition(all, 200ms, ease-in); 12 | 13 | &.primary{ 14 | background: $primary; 15 | } 16 | &.error{ 17 | background: $error; 18 | } 19 | &.success{ 20 | background: $success; 21 | } 22 | &.warn{ 23 | background: $warn; 24 | } 25 | &.danger{ 26 | background: $danger; 27 | } 28 | } -------------------------------------------------------------------------------- /app/styles/imports/welcome.scss: -------------------------------------------------------------------------------- 1 | .page-welcome{ 2 | 3 | background-color: #fff; 4 | padding: 6em 0; 5 | 6 | .ad{ 7 | border-radius: 4px; 8 | background-color: $tone-color; 9 | } 10 | 11 | .log-reg{ 12 | max-width: 300px; 13 | .input-group-addon, 14 | input{ 15 | border-radius: 0; 16 | box-shadow: none; 17 | } 18 | .slider-box{ 19 | overflow: hidden; 20 | } 21 | .login, 22 | .reg{ 23 | float: left; 24 | width: 50%; 25 | } 26 | .slider{ 27 | width: 200%; 28 | overflow: hidden; 29 | position: relative; 30 | left: 0; 31 | @include transition(all, .9s, $easeOutCirc); 32 | &.loging{ 33 | left: -100%; 34 | } 35 | } 36 | } 37 | 38 | .log-reg-btn{ 39 | 40 | } 41 | 42 | form{ 43 | position: relative; 44 | } 45 | 46 | button[type="submit"]{ 47 | position: absolute; 48 | bottom: 0; 49 | right: 0; 50 | z-index: 2; 51 | } 52 | 53 | .glyphicon-refresh{ 54 | -webkit-animation-name: rotate; 55 | animation-name: rotate; 56 | } 57 | } 58 | 59 | @media (max-width: $screen-xs-max) { 60 | .page-welcome{ 61 | padding: 1em 0; 62 | .log-reg{ 63 | max-width: none; 64 | margin-top: 2em; 65 | 66 | .slider{ 67 | @include transform(translate(0, 0)); 68 | &.loging{ 69 | left: 0; 70 | @include transform(translate(-50%, 0)); 71 | } 72 | } 73 | } 74 | } 75 | } -------------------------------------------------------------------------------- /app/views/404.html: -------------------------------------------------------------------------------- 1 |
2 | 3 |

:(

4 |
-------------------------------------------------------------------------------- /app/views/about.html: -------------------------------------------------------------------------------- 1 |
2 |
3 |

{{site.title}}

4 |
5 |
6 |
-------------------------------------------------------------------------------- /app/views/foot.html: -------------------------------------------------------------------------------- 1 |
{{Toast.text}}
2 | -------------------------------------------------------------------------------- /app/views/friend/fans.html: -------------------------------------------------------------------------------- 1 |
    2 |
  • 3 | 4 |
  • 5 |
6 | -------------------------------------------------------------------------------- /app/views/friend/follow.html: -------------------------------------------------------------------------------- 1 |
2 | 3 |
    4 |
  • 5 |
    6 |
  • 7 |
8 | 9 | 10 |
-------------------------------------------------------------------------------- /app/views/friend/friend.html: -------------------------------------------------------------------------------- 1 |
2 | 3 |
4 |
5 | 6 | 14 | 15 |
16 |
17 | 18 |
19 |
20 | 21 | 22 | 23 | 24 |
-------------------------------------------------------------------------------- /app/views/friend/side.html: -------------------------------------------------------------------------------- 1 |
2 | 3 |
4 |
推荐好友
5 | 35 |
36 | 37 |
-------------------------------------------------------------------------------- /app/views/home/answer.html: -------------------------------------------------------------------------------- 1 |
2 | 3 |
4 |
5 |
6 |
7 | 8 | 9 |
-------------------------------------------------------------------------------- /app/views/home/love.html: -------------------------------------------------------------------------------- 1 |
2 | 3 |
4 |
5 |
6 | 7 | 8 |
-------------------------------------------------------------------------------- /app/views/home/news.html: -------------------------------------------------------------------------------- 1 |
2 | 3 |
4 | 5 |
6 |
7 |
8 | 9 | 10 |
-------------------------------------------------------------------------------- /app/views/home/reply.html: -------------------------------------------------------------------------------- 1 |
2 | 3 |
4 |
5 |
6 | 7 | 8 |
-------------------------------------------------------------------------------- /app/views/home/side.html: -------------------------------------------------------------------------------- 1 |
2 |
3 |
每日一问
4 | 11 |
12 |
13 |
我的邀请码
14 |
    15 |
  • 16 |

    aaaa

    17 |
  • 18 |
  • 19 |

    bbb

    20 |
  • 21 |
  • 22 |

    ccc

    23 |
  • 24 |
25 |
26 |
27 |
反馈
28 |

m@mifan.us

29 |
30 |
-------------------------------------------------------------------------------- /app/views/login.html: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /app/views/me/answer.html: -------------------------------------------------------------------------------- 1 |
2 | 3 |
4 |
5 |
6 | 7 | 8 |
-------------------------------------------------------------------------------- /app/views/me/ask.html: -------------------------------------------------------------------------------- 1 |
2 | 3 |
    4 |
  • 5 |

    6 | {{ask.content}} 7 |

    8 |

    问了{{ask.ask_count}}位朋友,{{ask.answer_cout}}个回答,{{ask.addtime | ago}}

    9 |
  • 10 |
11 | 12 | 13 |
-------------------------------------------------------------------------------- /app/views/me/love.html: -------------------------------------------------------------------------------- 1 |
2 | 3 |
4 |
5 |
6 |
7 | 8 | 9 |
-------------------------------------------------------------------------------- /app/views/me/me.html: -------------------------------------------------------------------------------- 1 |
2 | 3 |
4 | 5 |
6 |
7 | 8 | 19 | 20 |
21 |
22 |
23 | 24 |
25 |
26 | 27 | 28 |
-------------------------------------------------------------------------------- /app/views/mobile/bill.html: -------------------------------------------------------------------------------- 1 |
2 | 3 |
4 |
    5 |
  • {{bill.name}}
  • 6 |
7 | 8 |
9 |
10 | 取消 11 |
12 |
13 |
14 | 15 |
16 |
-------------------------------------------------------------------------------- /app/views/mobile/design.html: -------------------------------------------------------------------------------- 1 |
2 | 3 |
4 | 取消 5 | 6 |

{{title}}

7 |
8 | 9 |
10 |
11 | 12 |
13 |
14 | 15 |
16 | -------------------------------------------------------------------------------- /app/views/mobile/menu.html: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /app/views/module/answer-form-mod.html: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /app/views/module/answer-mod.html: -------------------------------------------------------------------------------- 1 | {{news.answer.user.username}} 2 |

{{news.answer.content}}

3 | 4 |
5 | 6 | -------------------------------------------------------------------------------- /app/views/module/feed-mod.html: -------------------------------------------------------------------------------- 1 | 5 |
6 |

7 |

{{news.ask.content}}

8 |

9 |

{{news.answer.content}}

10 |

11 | {{news.answer.user.username}}{{news.ask.user.username}} 的回答于 {{news.answer.addtime | ago}} 12 |

13 | 14 |
15 |
-------------------------------------------------------------------------------- /app/views/module/follow-user-mod.html: -------------------------------------------------------------------------------- 1 | {{user.username}} 2 | 3 |
4 |

{{user.username}}

5 |

{{user.about || user.signed}}

6 |
7 | 8 | 9 | -------------------------------------------------------------------------------- /app/views/module/ques-mod.html: -------------------------------------------------------------------------------- 1 |
2 | {{askInfo.user.username}} 3 |

{{askInfo.content}}

4 |
5 | {{askInfo.user.username}} 提问于 {{askInfo.addtime | ago}} 6 |
7 |
-------------------------------------------------------------------------------- /app/views/msg.html: -------------------------------------------------------------------------------- 1 |
2 |
3 |

Tips: 支持ctrl + enter回复

4 | 5 |
6 |
7 | {{msg.user.username}} 8 |
9 | {{msg.content}} 10 |

{{msg.user.username}} 提问于 {{msg.addtime | ago}}

11 |
12 |
13 | ... 14 |
15 |
16 |
17 |
18 | 19 | 20 |
21 |
-------------------------------------------------------------------------------- /app/views/ques/ques.html: -------------------------------------------------------------------------------- 1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 | 10 |
11 |
-------------------------------------------------------------------------------- /app/views/search.html: -------------------------------------------------------------------------------- 1 |
2 |
3 |
4 |
5 |
6 | 7 | 8 | 9 | 10 |
11 | 12 |
13 | 14 |
15 |
16 |
17 |
-------------------------------------------------------------------------------- /app/views/square/feeds.html: -------------------------------------------------------------------------------- 1 |
2 | 3 | 4 |
5 |
6 |
7 | 8 | 9 |
-------------------------------------------------------------------------------- /app/views/square/side.html: -------------------------------------------------------------------------------- 1 |
2 |
3 |
最新加入米饭的
4 |
    5 |
  • 6 |
    7 |
  • 8 |
9 |
10 |
11 | 12 | -------------------------------------------------------------------------------- /app/views/square/square.html: -------------------------------------------------------------------------------- 1 |
2 | 3 |
4 |
5 | 6 |
7 |
米饭广场 - 大家都在问:
8 |
    9 |
  • 10 |
11 |
12 | 13 |
14 |
15 |
16 |
17 |
18 | 19 |
20 |
-------------------------------------------------------------------------------- /app/views/template/README.md: -------------------------------------------------------------------------------- 1 | 这里是 指令 模版。 -------------------------------------------------------------------------------- /app/views/template/error-msg.html: -------------------------------------------------------------------------------- 1 |

{{errorMsg}}

-------------------------------------------------------------------------------- /app/views/template/logintip.html: -------------------------------------------------------------------------------- 1 |
2 | 登录 3 |
-------------------------------------------------------------------------------- /app/views/template/more.html: -------------------------------------------------------------------------------- 1 |
2 | 7 |
8 | -------------------------------------------------------------------------------- /app/views/template/sending-btn.html: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /app/views/template/sns-login.html: -------------------------------------------------------------------------------- 1 | 6 | -------------------------------------------------------------------------------- /app/views/template/sub-nav.html: -------------------------------------------------------------------------------- 1 | 2 | -------------------------------------------------------------------------------- /app/views/template/ui-loading.html: -------------------------------------------------------------------------------- 1 |
-------------------------------------------------------------------------------- /app/views/template/usermenu.html: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /bower.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "mifan.us", 3 | "version": "0.0.0", 4 | "dependencies": { 5 | "angular": "1.2.15", 6 | "angular-resource": "1.2.15", 7 | "angular-cookies": "1.2.15", 8 | "angular-sanitize": "1.2.15", 9 | "angular-route": "1.2.15", 10 | "sass-css3-mixins": "*", 11 | "sass-easing": "*", 12 | "angular-touch": "~1.2.20", 13 | "binnng/time.js": "*", 14 | "binnng/debug.js": "*" 15 | }, 16 | "devDependencies": { 17 | "angular-mocks": "1.2.15", 18 | "angular-scenario": "1.2.15" 19 | } 20 | } 21 | -------------------------------------------------------------------------------- /package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "mifan.us", 3 | "version": "0.0.0", 4 | "dependencies": {}, 5 | "devDependencies": { 6 | "grunt": "~0.4.1", 7 | "grunt-autoprefixer": "~0.4.0", 8 | "grunt-bower-install": "~1.0.0", 9 | "grunt-concurrent": "~0.5.0", 10 | "grunt-contrib-clean": "~0.5.0", 11 | "grunt-contrib-compass": "~0.7.2", 12 | "grunt-contrib-concat": "~0.3.0", 13 | "grunt-contrib-connect": "~0.5.0", 14 | "grunt-contrib-copy": "~0.4.1", 15 | "grunt-contrib-cssmin": "~0.7.0", 16 | "grunt-contrib-htmlmin": "~0.1.3", 17 | "grunt-contrib-imagemin": "~0.3.0", 18 | "grunt-contrib-jshint": "~0.7.1", 19 | "grunt-contrib-uglify": "~0.2.0", 20 | "grunt-contrib-watch": "~0.5.2", 21 | "grunt-google-cdn": "~0.2.0", 22 | "grunt-newer": "~0.6.1", 23 | "grunt-ngmin": "~0.0.2", 24 | "grunt-rev": "~0.1.0", 25 | "grunt-svgmin": "~0.2.0", 26 | "grunt-usemin": "~2.0.0", 27 | "jshint-stylish": "~0.1.3", 28 | "load-grunt-tasks": "~0.4.0", 29 | "time-grunt": "~0.2.1", 30 | "grunt-karma": "~0.8.3", 31 | "karma-phantomjs-launcher": "~0.1.4", 32 | "karma": "~0.12.16", 33 | "karma-jasmine": "~0.2.2", 34 | "grunt-ng-template": "~0.1.1", 35 | "ip": "~0.3.0", 36 | "grunt-regex-replace": "~0.2.6", 37 | "grunt-contrib-rename": "0.0.3", 38 | "md5": "~1.0.0", 39 | "grunt-sftp-deploy": "~0.2.1", 40 | "grunt-open": "~0.2.3" 41 | }, 42 | "engines": { 43 | "node": ">=0.10.0" 44 | }, 45 | "scripts": { 46 | "test": "grunt test" 47 | } 48 | } -------------------------------------------------------------------------------- /service/admin/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 403 Forbidden 4 | 5 | 6 | 7 |

Directory access is forbidden.

8 | 9 | 10 | -------------------------------------------------------------------------------- /service/application/cache/.htaccess: -------------------------------------------------------------------------------- 1 | deny from all -------------------------------------------------------------------------------- /service/application/cache/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 403 Forbidden 4 | 5 | 6 | 7 |

Directory access is forbidden.

8 | 9 | 10 | -------------------------------------------------------------------------------- /service/application/config/hooks.php: -------------------------------------------------------------------------------- 1 | 'Acl', 16 | 'function' => 'filter', 17 | 'filename' => 'acl.php', 18 | 'filepath' => 'hooks', 19 | //'params' => '', 20 | ); 21 | 22 | 23 | /* End of file hooks.php */ 24 | /* Location: ./application/config/hooks.php */ -------------------------------------------------------------------------------- /service/application/config/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 403 Forbidden 4 | 5 | 6 | 7 |

Directory access is forbidden.

8 | 9 | 10 | -------------------------------------------------------------------------------- /service/application/config/ldap.php: -------------------------------------------------------------------------------- 1 | 22 | -------------------------------------------------------------------------------- /service/application/config/memcached.php: -------------------------------------------------------------------------------- 1 | array( 14 | 'hostname' => '115.29.49.123', 15 | 'port' => '11211', 16 | 'weight' => '1', 17 | ), 18 | ); 19 | 20 | 21 | /* End of file memcached.php */ 22 | /* Location: ./application/config/memcached.php */ -------------------------------------------------------------------------------- /service/application/config/profiler.php: -------------------------------------------------------------------------------- 1 | 2 | 3 | 403 Forbidden 4 | 5 | 6 | 7 |

Directory access is forbidden.

8 | 9 | 10 | -------------------------------------------------------------------------------- /service/application/core/MF_Controller.php: -------------------------------------------------------------------------------- 1 | 2 | 3 | 403 Forbidden 4 | 5 | 6 | 7 |

Directory access is forbidden.

8 | 9 | 10 | -------------------------------------------------------------------------------- /service/application/helpers/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 403 Forbidden 4 | 5 | 6 | 7 |

Directory access is forbidden.

8 | 9 | 10 | -------------------------------------------------------------------------------- /service/application/hooks/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 403 Forbidden 4 | 5 | 6 | 7 |

Directory access is forbidden.

8 | 9 | 10 | -------------------------------------------------------------------------------- /service/application/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 403 Forbidden 4 | 5 | 6 | 7 |

Directory access is forbidden.

8 | 9 | 10 | -------------------------------------------------------------------------------- /service/application/language/english/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 403 Forbidden 4 | 5 | 6 | 7 |

Directory access is forbidden.

8 | 9 | 10 | -------------------------------------------------------------------------------- /service/application/libraries/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 403 Forbidden 4 | 5 | 6 | 7 |

Directory access is forbidden.

8 | 9 | 10 | -------------------------------------------------------------------------------- /service/application/logs/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 403 Forbidden 4 | 5 | 6 | 7 |

Directory access is forbidden.

8 | 9 | 10 | -------------------------------------------------------------------------------- /service/application/models/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 403 Forbidden 4 | 5 | 6 | 7 |

Directory access is forbidden.

8 | 9 | 10 | -------------------------------------------------------------------------------- /service/application/third_party/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 403 Forbidden 4 | 5 | 6 | 7 |

Directory access is forbidden.

8 | 9 | 10 | -------------------------------------------------------------------------------- /service/application/third_party/rbac/config/memcached.php: -------------------------------------------------------------------------------- 1 | array('192.168.4.37:11211'), 13 | 'debug' => false 14 | ); 15 | 16 | /* End of file memcached.php */ 17 | /* Location: ./application/third_party/rbac/config/memcached.php */ -------------------------------------------------------------------------------- /service/application/third_party/rbac/config/rbac.php: -------------------------------------------------------------------------------- 1 | config->item('rbac_auth_gateway'),"请先登录!"); 21 | }else{ 22 | success_redirct($this->config->item('rbac_default_index'),"您已成功登录,正在跳转请稍候!","1"); 23 | } 24 | 25 | } 26 | /** 27 | * 用户登录 28 | */ 29 | public function login(){ 30 | 31 | $this->load->model("rbac_model"); 32 | $username = $this->input->post('username'); 33 | $password = $this->input->post('password'); 34 | if($username&&$password){ 35 | $STATUS = $this->rbac_model->check_user($username,md5($password)); 36 | if($STATUS===TRUE){ 37 | success_redirct($this->config->item('rbac_default_index'),"登录成功!"); 38 | }else{ 39 | error_redirct($this->config->item('rbac_auth_gateway'),$STATUS); 40 | die(); 41 | } 42 | }else{ 43 | $this->load->view("login"); 44 | } 45 | 46 | } 47 | /* 48 | * 用户退出 49 | */ 50 | public function logout(){ 51 | session_destroy(); 52 | success_redirct($this->config->item('rbac_auth_gateway'),"登出成功!",2); 53 | } 54 | 55 | } 56 | -------------------------------------------------------------------------------- /service/application/third_party/rbac/hooks/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 403 Forbidden 4 | 5 | 6 | 7 |

Directory access is forbidden.

8 | 9 | 10 | -------------------------------------------------------------------------------- /service/application/third_party/rbac/views/foot.php: -------------------------------------------------------------------------------- 1 |
2 |
3 |

Copyright @ ToryZen

4 |
5 |
6 | 7 | -------------------------------------------------------------------------------- /service/application/third_party/rbac/views/login.php: -------------------------------------------------------------------------------- 1 | load->view("head");?> 2 | 9 | 10 |
11 |
12 | 13 |
14 |
15 |
用户登录
16 |
17 | 18 |
19 |
20 | 用户 21 | 22 |
23 |
24 |
25 | 密码 26 | 27 |
28 |
29 |
30 |
31 | 32 | 33 |
34 |
35 |
36 |
37 |
38 |
测试用帐号(用户:admin 密码:admin)
39 |
40 |
41 |
42 | 43 | load->view("foot");?> -------------------------------------------------------------------------------- /service/application/third_party/rbac/views/main.php: -------------------------------------------------------------------------------- 1 | load->view("head");?> 2 | 3 |
4 |
5 | 8 |
9 | output->get_output();?> 10 |
11 |
12 |
13 | 14 | load->view("foot");?> -------------------------------------------------------------------------------- /service/application/third_party/rbac/views/manage/member.php: -------------------------------------------------------------------------------- 1 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 33 | ',$mb->id,$mb->username,$mb->nickname,$mb->email,($mb->rolename?$mb->rolename:"暂无角色"),($mb->status==1?"正常":"停用"),site_url("manage/member/edit/".$mb->id),site_url("manage/member/delete/".$mb->id)); 34 | } 35 | ?> 36 | 37 |
ID用户名昵称Email角色状态操作
%s%s%s%s%s%s 28 |
29 | 编辑 30 | 删除 31 |
32 |
38 |
39 | 40 | 新增用户'; ?> 41 | pagination->create_links(); ?> 42 | -------------------------------------------------------------------------------- /service/application/third_party/rbac/views/manage/member/add.php: -------------------------------------------------------------------------------- 1 |

新增用户

2 |
3 |
4 | 5 | 6 |
7 |
8 | 9 | 10 |
11 |
12 | 13 | 14 |
15 |
16 | 17 | 25 |
26 |
27 | 28 | 29 |
30 |
31 | 32 | 33 |
34 |
35 | 38 |
39 | 40 | 取消修改 41 |
-------------------------------------------------------------------------------- /service/application/third_party/rbac/views/manage/member/delete.php: -------------------------------------------------------------------------------- 1 | 5 |

您确定要删除此用户()?

6 | 7 |
8 | 9 | 10 | 取消修改 11 |
12 | -------------------------------------------------------------------------------- /service/application/third_party/rbac/views/manage/menu/add.php: -------------------------------------------------------------------------------- 1 |

新增子菜单

2 |
3 |
4 | 5 | 6 |
7 |
8 | 9 | 18 |
19 |
20 | 21 | 22 |
23 |
24 | 27 |
28 |
29 | 32 |
    33 |
  • 一级菜单建议不挂接节点,只当标题使用!
  • 34 |
  • 二级当标题时其下需有三级节点,否则将不显示!
  • 35 |
  • 三级菜单请挂接节点,否则将不会显示!
  • 36 |
37 |
38 | 39 | 40 | 41 | 取消修改 42 |
-------------------------------------------------------------------------------- /service/application/third_party/rbac/views/manage/menu/edit.php: -------------------------------------------------------------------------------- 1 |

修改子菜单

2 |
3 |
4 | 5 | 6 |
7 |
8 | 9 | 19 |
20 |
21 | 22 | 23 |
24 |
25 | 28 |
29 |
30 | 33 |
    34 |
  • 一级菜单建议不挂接节点,只当标题使用!
  • 35 |
  • 二级当标题时其下需有三级节点,否则将不显示!
  • 36 |
  • 三级菜单请挂接节点,否则将不会显示!
  • 37 |
38 |
39 | 40 | 41 | 42 | 43 | 取消修改 44 |
-------------------------------------------------------------------------------- /service/application/third_party/rbac/views/manage/node/add.php: -------------------------------------------------------------------------------- 1 |

新增节点

2 |
3 |
4 | 5 | > 6 |
7 |
8 | 9 | > 10 |
11 |
12 | 13 | > 14 |
15 |
16 | 17 | 18 |
19 |
20 | 23 |
24 | 25 | 取消操作 26 |
-------------------------------------------------------------------------------- /service/application/third_party/rbac/views/manage/node/delete.php: -------------------------------------------------------------------------------- 1 | 5 |

您确定要删除?

6 |

请慎重操作!

7 | 友情提示: 8 |
    9 |
  • 删除目录时将删除目录下多有控制器与方法!
  • 10 |
  • 删除控制器时将删除其下所有方法!
  • 11 |
  • 删除同时将取消其挂接的导航菜单
  • 12 |
13 |
14 |
15 | 16 | 17 | 取消操作 18 |
19 | -------------------------------------------------------------------------------- /service/application/third_party/rbac/views/manage/node/edit.php: -------------------------------------------------------------------------------- 1 |

节点修改

2 |
3 |
4 | 5 | 6 |
7 |
8 | 9 | 10 |
11 |
12 | 13 | 14 |
15 |
16 | 17 | 18 |
19 |
20 | 23 |
24 | 25 | 取消操作 26 |
-------------------------------------------------------------------------------- /service/application/third_party/rbac/views/manage/role.php: -------------------------------------------------------------------------------- 1 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 18 | 19 | 20 | 21 | 28 | ',$mb->id,$mb->rolename,($mb->status==1?"正常":"停用"),site_url("manage/role/edit/".$mb->id),site_url("manage/role/action/".$mb->id),site_url("manage/role/delete/".$mb->id)); 29 | } 30 | ?> 31 | 32 |
ID角色名称状态操作
%s%s%s 22 |
23 | 编辑角色 24 | 赋权节点 25 | 删除删除 26 |
27 |
33 |
34 | 35 | 新增角色'; ?> 36 | pagination->create_links(); ?> 37 | -------------------------------------------------------------------------------- /service/application/third_party/rbac/views/manage/role/action.php: -------------------------------------------------------------------------------- 1 | 5 | $mn){ 7 | echo ''; 8 | printf(' 9 | 10 | 11 | 12 | ',$key); 13 | foreach($mn as $mn_key=>$cmn){ 14 | printf(' 15 | 16 | 17 | 18 | ',$mn_key); 19 | foreach($cmn as $cmn_key=>$gcmn){ 20 | printf(' 21 | 22 | 23 | 27 | ',$gcmn->memo,(@$rnl[$key][$mn_key][$cmn_key]?"danger":"success"),site_url("manage/role/action/".$role_id."/".$gcmn->id),(@$rnl[$key][$mn_key][$cmn_key]?"取消授权":"节点授权")); 28 | } 29 | } 30 | echo '
%s
         %s
                 '.$cmn_key.'%s
24 | %s 25 |
26 |
'; 31 | } 32 | ?> 33 | -------------------------------------------------------------------------------- /service/application/third_party/rbac/views/manage/role/add.php: -------------------------------------------------------------------------------- 1 |

新增角色

2 |
3 |
4 | 5 | 6 |
7 |
8 | 11 |
12 | 13 | 取消修改 14 |
-------------------------------------------------------------------------------- /service/application/third_party/rbac/views/manage/role/delete.php: -------------------------------------------------------------------------------- 1 | 5 |

您确定要删除此角色()?

6 |

删除角色将同时删除角色的所有授权,请慎重操作!

7 | 8 |
9 | 10 | 11 | 取消修改 12 |
13 | -------------------------------------------------------------------------------- /service/application/third_party/rbac/views/manage/role/edit.php: -------------------------------------------------------------------------------- 1 |

角色编辑

2 |
3 |
4 | 5 | 6 |
7 |
8 | 11 |
12 | 13 | 14 | 取消修改 15 |
-------------------------------------------------------------------------------- /service/application/third_party/rbac/views/menu.php: -------------------------------------------------------------------------------- 1 | '; 5 | if($mn["self"]["uri"]=="/"){ 6 | $flist = " ".$mn["self"]["title"].""; 7 | }else{ 8 | $flist = anchor($mn["self"]["uri"],$mn["self"]["title"], array('class' => 'list-group-item')); 9 | } 10 | echo $flist; 11 | if(isset($mn["child"])){ 12 | foreach($mn["child"] as $cmn){ 13 | 14 | if(@$cmn["shown"]){ 15 | if($cmn["self"]["uri"]=="/"){ 16 | $slist = "     ".$cmn["self"]["title"].""; 17 | }else{ 18 | $slist = anchor($cmn["self"]["uri"],'    '.$cmn["self"]["title"], array('class' => 'list-group-item')); 19 | } 20 | echo $slist; 21 | if(isset($cmn["child"])){ 22 | foreach($cmn["child"] as $gcmn){ 23 | if(@$gcmn["shown"]){ 24 | $tlist = anchor($gcmn["self"]["uri"],"        ".$gcmn["self"]["title"], array('class' => 'list-group-item')); 25 | } 26 | echo $tlist; 27 | } 28 | } 29 | } 30 | 31 | } 32 | } 33 | echo '
'; 34 | } 35 | } 36 | 37 | ?> -------------------------------------------------------------------------------- /service/application/third_party/rbac/views/redirect.php: -------------------------------------------------------------------------------- 1 | load->view('head');?> 2 | 3 |
4 |
5 | 6 |
7 |
"> 8 |
9 |
10 | 11 |

12 |

秒钟后自动跳转!【立即跳转

13 |
14 | 15 |
16 |
17 |
18 |
19 |
20 | 32 | load->view("foot");?> -------------------------------------------------------------------------------- /service/application/views/errors/cli/error_404.php: -------------------------------------------------------------------------------- 1 | 2 | 3 | 403 Forbidden 4 | 5 | 6 | 7 |

Directory access is forbidden.

8 | 9 | 10 | -------------------------------------------------------------------------------- /service/application/views/errors/html/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 403 Forbidden 4 | 5 | 6 | 7 |

Directory access is forbidden.

8 | 9 | 10 | -------------------------------------------------------------------------------- /service/application/views/errors/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 403 Forbidden 4 | 5 | 6 | 7 |

Directory access is forbidden.

8 | 9 | 10 | -------------------------------------------------------------------------------- /service/application/views/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 403 Forbidden 4 | 5 | 6 | 7 |

Directory access is forbidden.

8 | 9 | 10 | -------------------------------------------------------------------------------- /service/cache/user/0/0/120/0666b88753_120_120.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/service/cache/user/0/0/120/0666b88753_120_120.jpg -------------------------------------------------------------------------------- /service/cache/user/0/0/120/4afecc5b6f_120_120.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/service/cache/user/0/0/120/4afecc5b6f_120_120.jpg -------------------------------------------------------------------------------- /service/cache/user/0/0/120/5c7a4bc555_120_120.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/service/cache/user/0/0/120/5c7a4bc555_120_120.jpg -------------------------------------------------------------------------------- /service/cache/user/0/0/120/6c9e391e64_120_120.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/service/cache/user/0/0/120/6c9e391e64_120_120.jpg -------------------------------------------------------------------------------- /service/cache/user/0/0/120/727ba6a82b_120_120.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/service/cache/user/0/0/120/727ba6a82b_120_120.jpg -------------------------------------------------------------------------------- /service/cache/user/0/0/120/7bc0598f90_120_120.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/service/cache/user/0/0/120/7bc0598f90_120_120.jpg -------------------------------------------------------------------------------- /service/cache/user/0/0/120/7dfecd76fb_120_120.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/service/cache/user/0/0/120/7dfecd76fb_120_120.png -------------------------------------------------------------------------------- /service/cache/user/0/0/120/81962d77d0_120_120.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/service/cache/user/0/0/120/81962d77d0_120_120.jpg -------------------------------------------------------------------------------- /service/cache/user/0/0/120/e09e8bb0d2_120_120.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/service/cache/user/0/0/120/e09e8bb0d2_120_120.jpg -------------------------------------------------------------------------------- /service/cache/user/0/0/120/e7f8839a7b_120_120.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/service/cache/user/0/0/120/e7f8839a7b_120_120.jpg -------------------------------------------------------------------------------- /service/cache/user/0/0/120/f0ae5e512f_120_120.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/service/cache/user/0/0/120/f0ae5e512f_120_120.jpg -------------------------------------------------------------------------------- /service/cache/user/0/0/60/0666b88753_60_60.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/service/cache/user/0/0/60/0666b88753_60_60.jpg -------------------------------------------------------------------------------- /service/cache/user/0/0/60/4afecc5b6f_60_60.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/service/cache/user/0/0/60/4afecc5b6f_60_60.jpg -------------------------------------------------------------------------------- /service/cache/user/0/0/60/5c7a4bc555_60_60.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/service/cache/user/0/0/60/5c7a4bc555_60_60.jpg -------------------------------------------------------------------------------- /service/cache/user/0/0/60/6c9e391e64_60_60.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/service/cache/user/0/0/60/6c9e391e64_60_60.jpg -------------------------------------------------------------------------------- /service/cache/user/0/0/60/727ba6a82b_60_60.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/service/cache/user/0/0/60/727ba6a82b_60_60.jpg -------------------------------------------------------------------------------- /service/cache/user/0/0/60/7bc0598f90_60_60.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/service/cache/user/0/0/60/7bc0598f90_60_60.jpg -------------------------------------------------------------------------------- /service/cache/user/0/0/60/7dfecd76fb_60_60.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/service/cache/user/0/0/60/7dfecd76fb_60_60.png -------------------------------------------------------------------------------- /service/cache/user/0/0/60/81962d77d0_60_60.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/service/cache/user/0/0/60/81962d77d0_60_60.jpg -------------------------------------------------------------------------------- /service/cache/user/0/0/60/e09e8bb0d2_60_60.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/service/cache/user/0/0/60/e09e8bb0d2_60_60.jpg -------------------------------------------------------------------------------- /service/cache/user/0/0/60/e7f8839a7b_60_60.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/service/cache/user/0/0/60/e7f8839a7b_60_60.jpg -------------------------------------------------------------------------------- /service/cache/user/0/0/60/f0ae5e512f_60_60.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/service/cache/user/0/0/60/f0ae5e512f_60_60.jpg -------------------------------------------------------------------------------- /service/shared/config/constant.php: -------------------------------------------------------------------------------- 1 | 2 | 3 | 403 Forbidden 4 | 5 | 6 | 7 |

Directory access is forbidden.

8 | 9 | 10 | -------------------------------------------------------------------------------- /service/shared/language/zh-cn/calendar_lang.php: -------------------------------------------------------------------------------- 1 | 2 | 3 | 403 Forbidden 4 | 5 | 6 | 7 |

Directory access is forbidden.

8 | 9 | 10 | -------------------------------------------------------------------------------- /service/shared/language/zh-cn/number_lang.php: -------------------------------------------------------------------------------- 1 | 2 | 3 | 403 Forbidden 4 | 5 | 6 | 7 |

Directory access is forbidden.

8 | 9 | 10 | -------------------------------------------------------------------------------- /service/system/core/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 403 Forbidden 4 | 5 | 6 | 7 |

Directory access is forbidden.

8 | 9 | 10 | -------------------------------------------------------------------------------- /service/system/database/drivers/cubrid/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 403 Forbidden 4 | 5 | 6 | 7 |

Directory access is forbidden.

8 | 9 | 10 | -------------------------------------------------------------------------------- /service/system/database/drivers/ibase/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 403 Forbidden 4 | 5 | 6 | 7 |

Directory access is forbidden.

8 | 9 | 10 | -------------------------------------------------------------------------------- /service/system/database/drivers/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 403 Forbidden 4 | 5 | 6 | 7 |

Directory access is forbidden.

8 | 9 | 10 | -------------------------------------------------------------------------------- /service/system/database/drivers/mssql/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 403 Forbidden 4 | 5 | 6 | 7 |

Directory access is forbidden.

8 | 9 | 10 | -------------------------------------------------------------------------------- /service/system/database/drivers/mysql/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 403 Forbidden 4 | 5 | 6 | 7 |

Directory access is forbidden.

8 | 9 | 10 | -------------------------------------------------------------------------------- /service/system/database/drivers/mysqli/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 403 Forbidden 4 | 5 | 6 | 7 |

Directory access is forbidden.

8 | 9 | 10 | -------------------------------------------------------------------------------- /service/system/database/drivers/oci8/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 403 Forbidden 4 | 5 | 6 | 7 |

Directory access is forbidden.

8 | 9 | 10 | -------------------------------------------------------------------------------- /service/system/database/drivers/odbc/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 403 Forbidden 4 | 5 | 6 | 7 |

Directory access is forbidden.

8 | 9 | 10 | -------------------------------------------------------------------------------- /service/system/database/drivers/pdo/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 403 Forbidden 4 | 5 | 6 | 7 |

Directory access is forbidden.

8 | 9 | 10 | -------------------------------------------------------------------------------- /service/system/database/drivers/pdo/pdo_forge.php: -------------------------------------------------------------------------------- 1 | db->display_error('db_unsupported_feature'); 48 | } 49 | 50 | } 51 | 52 | /* End of file pdo_utility.php */ 53 | /* Location: ./system/database/drivers/pdo/pdo_utility.php */ -------------------------------------------------------------------------------- /service/system/database/drivers/pdo/subdrivers/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 403 Forbidden 4 | 5 | 6 | 7 |

Directory access is forbidden.

8 | 9 | 10 | -------------------------------------------------------------------------------- /service/system/database/drivers/postgre/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 403 Forbidden 4 | 5 | 6 | 7 |

Directory access is forbidden.

8 | 9 | 10 | -------------------------------------------------------------------------------- /service/system/database/drivers/sqlite/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 403 Forbidden 4 | 5 | 6 | 7 |

Directory access is forbidden.

8 | 9 | 10 | -------------------------------------------------------------------------------- /service/system/database/drivers/sqlite3/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 403 Forbidden 4 | 5 | 6 | 7 |

Directory access is forbidden.

8 | 9 | 10 | -------------------------------------------------------------------------------- /service/system/database/drivers/sqlsrv/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 403 Forbidden 4 | 5 | 6 | 7 |

Directory access is forbidden.

8 | 9 | 10 | -------------------------------------------------------------------------------- /service/system/database/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 403 Forbidden 4 | 5 | 6 | 7 |

Directory access is forbidden.

8 | 9 | 10 | -------------------------------------------------------------------------------- /service/system/fonts/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 403 Forbidden 4 | 5 | 6 | 7 |

Directory access is forbidden.

8 | 9 | 10 | -------------------------------------------------------------------------------- /service/system/fonts/texb.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/imifan/mifan/b0cf250a71bb26a921bd1b6b1b4f2801ee531804/service/system/fonts/texb.ttf -------------------------------------------------------------------------------- /service/system/helpers/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 403 Forbidden 4 | 5 | 6 | 7 |

Directory access is forbidden.

8 | 9 | 10 | -------------------------------------------------------------------------------- /service/system/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 403 Forbidden 4 | 5 | 6 | 7 |

Directory access is forbidden.

8 | 9 | 10 | -------------------------------------------------------------------------------- /service/system/language/english/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 403 Forbidden 4 | 5 | 6 | 7 |

Directory access is forbidden.

8 | 9 | 10 | -------------------------------------------------------------------------------- /service/system/language/english/number_lang.php: -------------------------------------------------------------------------------- 1 | 2 | 3 | 403 Forbidden 4 | 5 | 6 | 7 |

Directory access is forbidden.

8 | 9 | 10 | -------------------------------------------------------------------------------- /service/system/libraries/Cache/drivers/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 403 Forbidden 4 | 5 | 6 | 7 |

Directory access is forbidden.

8 | 9 | 10 | -------------------------------------------------------------------------------- /service/system/libraries/Cache/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 403 Forbidden 4 | 5 | 6 | 7 |

Directory access is forbidden.

8 | 9 | 10 | -------------------------------------------------------------------------------- /service/system/libraries/Session/drivers/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 403 Forbidden 4 | 5 | 6 | 7 |

Directory access is forbidden.

8 | 9 | 10 | -------------------------------------------------------------------------------- /service/system/libraries/Session/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 403 Forbidden 4 | 5 | 6 | 7 |

Directory access is forbidden.

8 | 9 | 10 | -------------------------------------------------------------------------------- /service/system/libraries/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 403 Forbidden 4 | 5 | 6 | 7 |

Directory access is forbidden.

8 | 9 | 10 | -------------------------------------------------------------------------------- /service/system/libraries/javascript/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 403 Forbidden 4 | 5 | 6 | 7 |

Directory access is forbidden.

8 | 9 | 10 | --------------------------------------------------------------------------------