作者 lihongjuan

1

要显示太多修改。

为保证性能只显示 30 of 30+ 个文件。

  1 +.DS_Store
  2 +node_modules/
  3 +unpackage/
  4 +dist/
  5 +
  6 +# local env files
  7 +.env.local
  8 +.env.*.local
  9 +
  10 +# Log files
  11 +npm-debug.log*
  12 +yarn-debug.log*
  13 +yarn-error.log*
  14 +
  15 +# Editor directories and files
  16 +.project
  17 +.idea
  18 +.vscode
  19 +*.suo
  20 +*.ntvs*
  21 +*.njsproj
  22 +*.sln
  23 +*.sw*
  1 +# school
  2 +
  3 +## Project setup
  4 +```
  5 +npm install
  6 +```
  7 +
  8 +### Compiles and hot-reloads for development
  9 +```
  10 +npm run serve
  11 +```
  12 +
  13 +### Compiles and minifies for production
  14 +```
  15 +npm run build
  16 +```
  17 +
  18 +### Customize configuration
  19 +See [Configuration Reference](https://cli.vuejs.org/config/).
  1 +const plugins = []
  2 +
  3 +if (process.env.UNI_OPT_TREESHAKINGNG) {
  4 + plugins.push(require('@dcloudio/vue-cli-plugin-uni-optimize/packages/babel-plugin-uni-api/index.js'))
  5 +}
  6 +
  7 +if (
  8 + (
  9 + process.env.UNI_PLATFORM === 'app-plus' &&
  10 + process.env.UNI_USING_V8
  11 + ) ||
  12 + (
  13 + process.env.UNI_PLATFORM === 'h5' &&
  14 + process.env.UNI_H5_BROWSER === 'builtin'
  15 + )
  16 +) {
  17 + const path = require('path')
  18 +
  19 + const isWin = /^win/.test(process.platform)
  20 +
  21 + const normalizePath = path => (isWin ? path.replace(/\\/g, '/') : path)
  22 +
  23 + const input = normalizePath(process.env.UNI_INPUT_DIR)
  24 + try {
  25 + plugins.push([
  26 + require('@dcloudio/vue-cli-plugin-hbuilderx/packages/babel-plugin-console'),
  27 + {
  28 + file (file) {
  29 + file = normalizePath(file)
  30 + if (file.indexOf(input) === 0) {
  31 + return path.relative(input, file)
  32 + }
  33 + return false
  34 + }
  35 + }
  36 + ])
  37 + } catch (e) {}
  38 +}
  39 +
  40 +process.UNI_LIBRARIES = process.UNI_LIBRARIES || ['@dcloudio/uni-ui']
  41 +process.UNI_LIBRARIES.forEach(libraryName => {
  42 + plugins.push([
  43 + 'import',
  44 + {
  45 + 'libraryName': libraryName,
  46 + 'customName': (name) => {
  47 + return `${libraryName}/lib/${name}/${name}`
  48 + }
  49 + }
  50 + ])
  51 +})
  52 +module.exports = {
  53 + presets: [
  54 + [
  55 + '@vue/app',
  56 + {
  57 + modules: 'commonjs',
  58 + useBuiltIns: process.env.UNI_PLATFORM === 'h5' ? 'usage' : 'entry'
  59 + }
  60 + ]
  61 + ],
  62 + plugins
  63 +}
此 diff 太大无法显示。
  1 +{
  2 + "name": "school",
  3 + "version": "0.1.0",
  4 + "private": true,
  5 + "scripts": {
  6 + "serve": "npm run dev:h5",
  7 + "build": "npm run build:h5",
  8 + "build:app-plus": "cross-env NODE_ENV=production UNI_PLATFORM=app-plus vue-cli-service uni-build",
  9 + "build:custom": "cross-env NODE_ENV=production uniapp-cli custom",
  10 + "build:h5": "cross-env NODE_ENV=production UNI_PLATFORM=h5 vue-cli-service uni-build",
  11 + "build:mp-alipay": "cross-env NODE_ENV=production UNI_PLATFORM=mp-alipay vue-cli-service uni-build",
  12 + "build:mp-baidu": "cross-env NODE_ENV=production UNI_PLATFORM=mp-baidu vue-cli-service uni-build",
  13 + "build:mp-qq": "cross-env NODE_ENV=production UNI_PLATFORM=mp-qq vue-cli-service uni-build",
  14 + "build:mp-toutiao": "cross-env NODE_ENV=production UNI_PLATFORM=mp-toutiao vue-cli-service uni-build",
  15 + "build:mp-weixin": "cross-env NODE_ENV=production UNI_PLATFORM=mp-weixin vue-cli-service uni-build",
  16 + "build:quickapp": "cross-env NODE_ENV=production UNI_PLATFORM=quickapp vue-cli-service uni-build",
  17 + "dev:app-plus": "cross-env NODE_ENV=development UNI_PLATFORM=app-plus vue-cli-service uni-build --watch",
  18 + "dev:custom": "cross-env NODE_ENV=development uniapp-cli custom",
  19 + "dev:h5": "cross-env NODE_ENV=development UNI_PLATFORM=h5 vue-cli-service uni-serve",
  20 + "dev:mp-alipay": "cross-env NODE_ENV=development UNI_PLATFORM=mp-alipay vue-cli-service uni-build --watch",
  21 + "dev:mp-baidu": "cross-env NODE_ENV=development UNI_PLATFORM=mp-baidu vue-cli-service uni-build --watch",
  22 + "dev:mp-qq": "cross-env NODE_ENV=development UNI_PLATFORM=mp-qq vue-cli-service uni-build --watch",
  23 + "dev:mp-toutiao": "cross-env NODE_ENV=development UNI_PLATFORM=mp-toutiao vue-cli-service uni-build --watch",
  24 + "dev:mp-weixin": "cross-env NODE_ENV=development UNI_PLATFORM=mp-weixin vue-cli-service uni-build --watch",
  25 + "dev:quickapp": "cross-env NODE_ENV=development UNI_PLATFORM=quickapp vue-cli-service uni-build --watch",
  26 + "info": "node node_modules/@dcloudio/vue-cli-plugin-uni/commands/info.js",
  27 + "serve:quickapp": "node node_modules/@dcloudio/uni-quickapp/bin/serve.js"
  28 + },
  29 + "dependencies": {
  30 + "@dcloudio/uni-app-plus": "^2.0.0-26920200403001",
  31 + "@dcloudio/uni-h5": "^2.0.0-26920200403001",
  32 + "@dcloudio/uni-helper-json": "*",
  33 + "@dcloudio/uni-mp-alipay": "^2.0.0-26920200403001",
  34 + "@dcloudio/uni-mp-baidu": "^2.0.0-26920200403001",
  35 + "@dcloudio/uni-mp-qq": "^2.0.0-26920200403001",
  36 + "@dcloudio/uni-mp-toutiao": "^2.0.0-26920200403001",
  37 + "@dcloudio/uni-mp-weixin": "^2.0.0-26920200403001",
  38 + "@dcloudio/uni-stat": "^2.0.0-26920200403001",
  39 + "core-js": "^3.6.4",
  40 + "flyio": "^0.6.2",
  41 + "less": "^3.11.1",
  42 + "less-loader": "^5.0.0",
  43 + "regenerator-runtime": "^0.12.1",
  44 + "vue": "^2.6.11",
  45 + "vuex": "^3.0.1"
  46 + },
  47 + "devDependencies": {
  48 + "@dcloudio/uni-cli-shared": "^2.0.0-26920200403001",
  49 + "@dcloudio/uni-migration": "^2.0.0-26920200403001",
  50 + "@dcloudio/uni-template-compiler": "^2.0.0-26920200403001",
  51 + "@dcloudio/vue-cli-plugin-hbuilderx": "^2.0.0-26920200403001",
  52 + "@dcloudio/vue-cli-plugin-uni": "^2.0.0-26920200403001",
  53 + "@dcloudio/vue-cli-plugin-uni-optimize": "^2.0.0-26920200403001",
  54 + "@dcloudio/webpack-uni-mp-loader": "^2.0.0-26920200403001",
  55 + "@dcloudio/webpack-uni-pages-loader": "^2.0.0-26920200403001",
  56 + "@types/html5plus": "*",
  57 + "@types/uni-app": "*",
  58 + "@vue/cli-plugin-babel": "^4.3.0",
  59 + "@vue/cli-service": "^4.3.0",
  60 + "babel-plugin-import": "^1.11.0",
  61 + "cross-env": "^7.0.2",
  62 + "mini-types": "*",
  63 + "miniprogram-api-typings": "^2.8.0-2",
  64 + "postcss-comment": "^2.0.0",
  65 + "vue-template-compiler": "^2.6.11"
  66 + },
  67 + "browserslist": [
  68 + "Android >= 4",
  69 + "ios >= 8"
  70 + ],
  71 + "uni-app": {
  72 + "scripts": {}
  73 + }
  74 +}
  1 +const path = require('path')
  2 +module.exports = {
  3 + parser: require('postcss-comment'),
  4 + plugins: [
  5 + require('postcss-import')({
  6 + resolve (id, basedir, importOptions) {
  7 + if (id.startsWith('~@/')) {
  8 + return path.resolve(process.env.UNI_INPUT_DIR, id.substr(3))
  9 + } else if (id.startsWith('@/')) {
  10 + return path.resolve(process.env.UNI_INPUT_DIR, id.substr(2))
  11 + } else if (id.startsWith('/') && !id.startsWith('//')) {
  12 + return path.resolve(process.env.UNI_INPUT_DIR, id.substr(1))
  13 + }
  14 + return id
  15 + }
  16 + }),
  17 + require('autoprefixer')({
  18 + remove: process.env.UNI_PLATFORM !== 'h5'
  19 + }),
  20 + require('@dcloudio/vue-cli-plugin-uni/packages/postcss')
  21 + ]
  22 +}
  1 +<!DOCTYPE html>
  2 +<html lang="zh-CN">
  3 +
  4 + <head>
  5 + <meta charset="utf-8">
  6 + <meta http-equiv="X-UA-Compatible" content="IE=edge">
  7 + <title>
  8 + <%= htmlWebpackPlugin.options.title %>
  9 + </title>
  10 + <script>
  11 + document.addEventListener('DOMContentLoaded', function() {
  12 + document.documentElement.style.fontSize = document.documentElement.clientWidth / 20 + 'px'
  13 + })
  14 + var coverSupport = 'CSS' in window && typeof CSS.supports === 'function' && (CSS.supports('top: env(a)') || CSS.supports('top: constant(a)'))
  15 + document.write('<meta name="viewport" content="width=device-width, user-scalable=no, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0' + (coverSupport ? ', viewport-fit=cover' : '') + '" />')
  16 + </script>
  17 + <link rel="stylesheet" href="<%= BASE_URL %>static/index.<%= VUE_APP_INDEX_CSS_HASH %>.css" />
  18 + </head>
  19 +
  20 + <body>
  21 + <noscript>
  22 + <strong>Please enable JavaScript to continue.</strong>
  23 + </noscript>
  24 + <div id="app"></div>
  25 + <!-- built files will be auto injected -->
  26 + </body>
  27 +
  28 +</html>
  1 +<script>
  2 + export default {
  3 + onLaunch: function() {
  4 + console.log('App Launch')
  5 + },
  6 + onShow: function() {
  7 + console.log('App Show')
  8 + },
  9 + onHide: function() {
  10 + console.log('App Hide')
  11 + },
  12 + post: function(url, data,method) {
  13 + var promise = new Promise((resolve, reject) => {
  14 + //init
  15 + let that = this,
  16 + token = uni.getStorageSync('token'),
  17 + header = {
  18 + 'token': token || ''
  19 + },
  20 + postData;
  21 + //网络请求
  22 + uni.request({
  23 + url: this.globalData.baseUrl + url,
  24 + data: data,
  25 + method: method,
  26 + header: header,
  27 + success: function(res) {
  28 + console.log(res)
  29 +
  30 + //返回取得的数据
  31 + if (res.data.code == '1') {
  32 + resolve(res.data.data);
  33 + }else {
  34 + // uni.showToast({
  35 + // title: res.data.msg,
  36 + // icon: 'none'
  37 + // });
  38 + reject(res.data);
  39 + }
  40 + },
  41 + fail: function(e) {
  42 + reject('网络出错');
  43 + uni.hideNavigationBarLoading();
  44 + }
  45 + });
  46 + });
  47 + return promise;
  48 + },
  49 +
  50 +
  51 + upload(filetype, file) {
  52 + var promise = new Promise((resolve, reject) => {
  53 + wx.showNavigationBarLoading()
  54 + wx.showLoading({
  55 + title: '上传中',
  56 + })
  57 + let url = 'https://school.t.brotop.cn/api/common/upload';
  58 + let head = {
  59 + 'token':uni.getStorageSync('token'),
  60 + 'XX-Device-Type': ''
  61 + }
  62 + console.log(head)
  63 + let typename = {
  64 + filetype: filetype
  65 + }
  66 + wx.uploadFile({
  67 + url: url, //仅为示例,非真实的接口地址
  68 + filePath: file,
  69 + name: 'file',
  70 + header: head,
  71 + formData: typename,
  72 + success: function (res) {
  73 + console.log(res)
  74 + console.log('上传文件后', res)
  75 + let temdata = JSON.parse(res.data);
  76 + console.log(temdata)
  77 + let urlobj = {
  78 + url: temdata.data.url,
  79 + kurl: temdata.data.save_path
  80 + }
  81 + resolve(urlobj);
  82 +
  83 + },
  84 + fail: function (res) {
  85 + reject('网络出错');
  86 + wx.hideNavigationBarLoading()
  87 + wx.hideLoading()
  88 + },
  89 + complete: () => {
  90 + wx.hideNavigationBarLoading()
  91 + wx.hideLoading()
  92 + },
  93 + })
  94 + });
  95 + return promise;
  96 + },
  97 + globalData: {
  98 + userInfo: null,
  99 + baseUrl: 'https://school.t.brotop.cn/api/',
  100 + imageBaseUrl: 'http://school.t.brotop.cn'
  101 + },
  102 + }
  103 +</script>
  104 +
  105 +<style lang="less">
  106 + /*每个页面公共css */
  107 + button::after{
  108 + border:none;
  109 + outline:none;
  110 + }
  111 +.teacherfooter {
  112 + width: 750rpx;
  113 + display: flex;
  114 + align-items: center;
  115 + justify-content: space-between;
  116 + padding: 18rpx 82rpx;
  117 + box-sizing: border-box;
  118 + position: fixed;
  119 + bottom: 0;
  120 + left: 0;
  121 + background: #fff;
  122 + font-size: 22rpx;
  123 + .teacherfootitem {
  124 + display: felx;
  125 + flex-direction: column;
  126 + align-items: center;
  127 + justify-content: center;
  128 + .teacherfootitemtop {
  129 + margin: 0 auto;
  130 + display: flex;
  131 + justify-content: center;
  132 + image {
  133 + width: 48rpx;
  134 + height: 48rpx;
  135 + margin: 0 auto;
  136 + }
  137 + }
  138 + }
  139 + }
  140 +
  141 +.collegefooter{
  142 + width: 750rpx;
  143 + display: flex;
  144 + align-items: center;
  145 + justify-content: space-between;
  146 + padding: 18rpx 82rpx;
  147 + box-sizing: border-box;
  148 + position: fixed;
  149 + bottom: 0;
  150 + left: 0;
  151 + background: #fff;
  152 + font-size: 22rpx;
  153 + .teacherfootitem {
  154 + display: felx;
  155 + flex-direction: column;
  156 + align-items: center;
  157 + justify-content: center;
  158 + width: 50%;
  159 + text-align: center;
  160 + .teacherfootitemtop {
  161 + margin: 0 auto;
  162 + display: flex;
  163 + justify-content: center;
  164 + image {
  165 + width: 48rpx;
  166 + height: 48rpx;
  167 + margin: 0 auto;
  168 + }
  169 + }
  170 + }
  171 +}
  172 +
  173 +
  174 +
  175 + .shou {
  176 + width: 37rpx;
  177 + height: 37rpx;
  178 + font-size: 0;
  179 + }
  180 +
  181 +
  182 + .selactive{
  183 + color:#2D5575
  184 + }
  185 +</style>
  1 +import Vue from 'vue'
  2 +import App from './App'
  3 +
  4 +Vue.config.productionTip = false
  5 +
  6 +App.mpType = 'app'
  7 +
  8 +const app = new Vue({
  9 + ...App
  10 +})
  11 +app.$mount()
  1 +{
  2 + "name" : "school",
  3 + "appid" : "",
  4 + "description" : "",
  5 + "versionName" : "1.0.0",
  6 + "versionCode" : "100",
  7 + "transformPx" : false,
  8 + "app-plus" : {
  9 + /* 5+App特有相关 */
  10 + "usingComponents" : true,
  11 + "splashscreen" : {
  12 + "alwaysShowBeforeRender" : true,
  13 + "waiting" : true,
  14 + "autoclose" : true,
  15 + "delay" : 0
  16 + },
  17 + "modules" : {},
  18 + /* 模块配置 */
  19 + "distribute" : {
  20 + /* 应用发布信息 */
  21 + "android" : {
  22 + /* android打包配置 */
  23 + "permissions" : [
  24 + "<uses-permission android:name=\"android.permission.CHANGE_NETWORK_STATE\"/>",
  25 + "<uses-permission android:name=\"android.permission.MOUNT_UNMOUNT_FILESYSTEMS\"/>",
  26 + "<uses-permission android:name=\"android.permission.READ_CONTACTS\"/>",
  27 + "<uses-permission android:name=\"android.permission.VIBRATE\"/>",
  28 + "<uses-permission android:name=\"android.permission.READ_LOGS\"/>",
  29 + "<uses-permission android:name=\"android.permission.ACCESS_WIFI_STATE\"/>",
  30 + "<uses-feature android:name=\"android.hardware.camera.autofocus\"/>",
  31 + "<uses-permission android:name=\"android.permission.WRITE_CONTACTS\"/>",
  32 + "<uses-permission android:name=\"android.permission.ACCESS_NETWORK_STATE\"/>",
  33 + "<uses-permission android:name=\"android.permission.CAMERA\"/>",
  34 + "<uses-permission android:name=\"android.permission.RECORD_AUDIO\"/>",
  35 + "<uses-permission android:name=\"android.permission.GET_ACCOUNTS\"/>",
  36 + "<uses-permission android:name=\"android.permission.MODIFY_AUDIO_SETTINGS\"/>",
  37 + "<uses-permission android:name=\"android.permission.READ_PHONE_STATE\"/>",
  38 + "<uses-permission android:name=\"android.permission.CHANGE_WIFI_STATE\"/>",
  39 + "<uses-permission android:name=\"android.permission.WAKE_LOCK\"/>",
  40 + "<uses-permission android:name=\"android.permission.CALL_PHONE\"/>",
  41 + "<uses-permission android:name=\"android.permission.FLASHLIGHT\"/>",
  42 + "<uses-permission android:name=\"android.permission.ACCESS_COARSE_LOCATION\"/>",
  43 + "<uses-feature android:name=\"android.hardware.camera\"/>",
  44 + "<uses-permission android:name=\"android.permission.ACCESS_FINE_LOCATION\"/>",
  45 + "<uses-permission android:name=\"android.permission.WRITE_SETTINGS\"/>"
  46 + ]
  47 + },
  48 + "ios" : {},
  49 + /* ios打包配置 */
  50 + "sdkConfigs" : {}
  51 + }
  52 + },
  53 + /* SDK配置 */
  54 + "quickapp" : {},
  55 + /* 快应用特有相关 */
  56 + "mp-weixin" : {
  57 + "appid" : "wxf06ef1898e5e6d55",
  58 + "setting" : {
  59 + "urlCheck" : true,
  60 + "minified" : true
  61 + },
  62 + "usingComponents" : true
  63 + },
  64 + "mp-alipay" : {
  65 + "usingComponents" : true
  66 + },
  67 + "mp-baidu" : {
  68 + "usingComponents" : true
  69 + },
  70 + "mp-toutiao" : {
  71 + "usingComponents" : true
  72 + },
  73 + "mp-qq" : {
  74 + "usingComponents" : true
  75 + }
  76 +}
  1 +{
  2 + "pages": [
  3 + {
  4 + "path": "pages/school/school",
  5 + "style": {
  6 + "navigationBarTitleText": "学长说",
  7 + "navigationBarBackgroundColor": "#2D5575",
  8 + "navigationBarTextStyle": "white"
  9 +
  10 + }
  11 + },
  12 + {
  13 + "path": "pages/register/register",
  14 + "style": {
  15 + "navigationBarTitleText": "学长说",
  16 + "navigationBarBackgroundColor": "#2D5575",
  17 + "navigationBarTextStyle": "white"
  18 +
  19 + }
  20 + },{
  21 + "path": "pages/register/highRegister",
  22 + "style": {
  23 + "navigationBarTitleText": "学长说",
  24 + "navigationBarBackgroundColor": "#2D5575",
  25 + "navigationBarTextStyle": "white"
  26 +
  27 + }
  28 + },
  29 +
  30 + {
  31 + "path": "pages/register/selectSchool",
  32 + "style": {
  33 + "navigationBarTitleText": "学长说",
  34 + "navigationBarTextStyle": "black"
  35 +
  36 + }
  37 + },{
  38 + "path": "pages/register/addSchool",
  39 + "style": {
  40 + "navigationBarTitleText": "学长说",
  41 + "navigationBarTextStyle": "black"
  42 +
  43 + }
  44 + },{
  45 + "path": "pages/register/college",
  46 + "style": {
  47 + "navigationBarTitleText": "学长说",
  48 + "navigationBarBackgroundColor": "#2D5575",
  49 + "navigationBarTextStyle": "white"
  50 +
  51 + }
  52 + },{
  53 + "path": "pages/register/selectCollege",
  54 + "style": {
  55 + "navigationBarTitleText": "学长说"
  56 + }
  57 + },{
  58 + "path": "pages/register/selectAcademy",
  59 + "style": {
  60 + "navigationBarTitleText": "学长说"
  61 + }
  62 + },{
  63 + "path": "pages/register/selectMajor",
  64 + "style": {
  65 + "navigationBarTitleText": "学长说"
  66 + }
  67 + },{
  68 + "path": "pages/schoolmate/schoolmate",
  69 + "style": {
  70 + "navigationBarTitleText": "学长说",
  71 + "navigationBarBackgroundColor": "#2D5575",
  72 + "navigationBarTextStyle": "white"
  73 +
  74 + }
  75 + }
  76 + ,{
  77 + "path": "pages/homePage/homePage",
  78 + "style": {
  79 + "navigationBarTitleText": "学长说",
  80 + "navigationBarBackgroundColor": "#2D5575",
  81 + "navigationBarTextStyle": "white"
  82 +
  83 + }
  84 + },{
  85 + "path": "pages/homePage/collegeHome",
  86 + "style": {
  87 + "navigationBarTitleText": "学长说",
  88 + "navigationBarBackgroundColor": "#2D5575",
  89 + "navigationBarTextStyle": "white"
  90 +
  91 + }
  92 + },{
  93 + "path": "pages/school/schoolDetails",
  94 + "style": {
  95 + "navigationBarTitleText": "学长说",
  96 + "app-plus":{
  97 + "titleNView":false
  98 +
  99 + }
  100 + }
  101 + },{
  102 + "path": "pages/school/schoolMsg",
  103 + "style": {
  104 + "navigationBarTitleText": "学长说",
  105 + "navigationBarBackgroundColor": "#2D5575",
  106 + "navigationBarTextStyle": "white"
  107 +
  108 + }
  109 + },{
  110 + "path": "pages/school/highSchoolmate",
  111 + "style": {
  112 + "navigationBarTitleText": "学长说",
  113 + "navigationBarBackgroundColor": "#2D5575",
  114 + "navigationBarTextStyle": "white"
  115 +
  116 + }
  117 + },{
  118 + "path": "pages/school/schoolmateMsg",
  119 + "style": {
  120 + "navigationBarTitleText": "学长说",
  121 + "navigationBarBackgroundColor": "#2D5575",
  122 + "navigationBarTextStyle": "white"
  123 +
  124 + }
  125 + }
  126 + ,{
  127 + "path": "pages/homePage/buyCard",
  128 + "style": {
  129 + "navigationBarTitleText": "畅读卡",
  130 + "navigationBarBackgroundColor": "#2D5575",
  131 + "navigationBarTextStyle": "white"
  132 +
  133 + }
  134 + },{
  135 + "path": "pages/school/academy",
  136 + "style": {
  137 + "navigationBarTitleText": "学长说"
  138 + }
  139 + }
  140 + ,{
  141 + "path": "pages/school/academyDetails",
  142 + "style": {
  143 + "navigationBarTitleText": "学长说",
  144 + "navigationBarBackgroundColor": "#2D5575",
  145 + "navigationBarTextStyle": "white"
  146 +
  147 + }
  148 + }
  149 + ,{
  150 + "path": "pages/school/article",
  151 + "style": {
  152 + "navigationBarTitleText": "学长说"
  153 + }
  154 + }
  155 + ,{
  156 + "path": "pages/school/searchSchool",
  157 + "style": {
  158 + "navigationBarTitleText": "学长说"
  159 + }
  160 + }
  161 + ,{
  162 + "path": "pages/homePage/gerencenter",
  163 + "style": {
  164 + "navigationBarTitleText": "个人中心"
  165 + }
  166 + }
  167 + ,{
  168 + "path": "pages/homePage/collegegerencenter",
  169 + "style": {
  170 + "navigationBarTitleText": "个人中心"
  171 + }
  172 + }
  173 + ,{
  174 + "path": "pages/homePage/cellect",
  175 + "style": {
  176 + "navigationBarTitleText": "收藏文章"
  177 + }
  178 + },{
  179 + "path": "pages/homePage/collegeCellect",
  180 + "style": {
  181 + "navigationBarTitleText": "我的文章"
  182 + }
  183 + },
  184 + {
  185 + "path": "pages/homePage/consumePage",
  186 + "style": {
  187 + "navigationBarTitleText": "消费记录"
  188 + }
  189 + },{
  190 + "path": "pages/homePage/mywallet",
  191 + "style": {
  192 + "navigationBarTitleText": "我的钱包"
  193 + }
  194 + },
  195 + {
  196 + "path": "pages/homePage/followPeople",
  197 + "style": {
  198 + "navigationBarTitleText": "关注的人"
  199 + }
  200 + },
  201 + {
  202 + "path": "pages/homePage/mycomment",
  203 + "style": {
  204 + "navigationBarTitleText": "我的留言"
  205 + }
  206 + },
  207 + {
  208 + "path": "pages/homePage/commentContent",
  209 + "style": {
  210 + "navigationBarTitleText": "留言详情"
  211 + }
  212 + },
  213 + {
  214 + "path": "pages/homePage/pubArticle",
  215 + "style": {
  216 + "navigationBarTitleText": "发表文章"
  217 + }
  218 + },{
  219 + "path": "pages/homePage/yuE",
  220 + "style": {
  221 + "navigationBarTitleText": "余额明细"
  222 + }
  223 + },
  224 + {
  225 + "path": "pages/homePage/tixianPage",
  226 + "style": {
  227 + "navigationBarTitleText": "立即提现",
  228 + "navigationBarBackgroundColor": "#2D5575",
  229 + "navigationBarTextStyle": "white"
  230 +
  231 + }
  232 + },{
  233 + "path": "pages/index/index",
  234 + "style": {
  235 + "navigationBarTitleText": "uni-app"
  236 + }
  237 + }
  238 +
  239 + ],
  240 +
  241 +
  242 + "globalStyle": {
  243 + "navigationBarTextStyle": "black",
  244 + "navigationBarTitleText": "uni-app",
  245 + "navigationBarBackgroundColor": "#ffffff",
  246 + "backgroundColor": "white"
  247 + }
  248 +
  249 +}
  1 +<template>
  2 + <view class="content">
  3 + <image class="bg" src="../../static/bg_img@2x(2).png"></image>
  4 + <image class="card" src="../../static/card_img@2x.png"></image>
  5 + <view class="cardText">
  6 +
  7 + <swiper class="swiper" :indicator-dots="indicatorDots" :autoplay="autoplay" :interval="interval" :duration="duration" :indicator-color="indicatorColor" :indicator-active-color="indicatorActiveColor" @change="swiperChange" :circle="true" circular="true">
  8 + <view v-for="(item,index) in cardlist" :key="index">
  9 + <swiper-item>
  10 +
  11 + <view class="title">城市畅读卡</view>
  12 + <view class="money">{{item.money}}/月</view>
  13 + <view class="time" v-if="item.vip_endtime">到期日期:{{item.vip_endtime}}</view>
  14 + <view class="btn" v-if="item.vip_endtime==''" @click="buycard" :data-id="item.vip_level">立即购买<image class="icon" src="../../static/dizhi_btn@2x2.png"></image></view>
  15 + <!-- <image class="big" src="../../static/juxing.png"></image>
  16 + <image class="small" src="../../static/tuoyuan.png"></image> -->
  17 +
  18 + </swiper-item>
  19 + </view>
  20 +
  21 + </swiper>
  22 + <view class="dots">
  23 + <block v-for="(item,index) in cardlist" :key="index">
  24 + <view class="dot" :class="index == currentSwiper ? 'active' : ''"></view>
  25 + </block>
  26 + </view>
  27 + </view>
  28 + <view class="textBox">
  29 + YHA青年旅舍会员卡(一年)是国际青年旅舍联盟会员身份证明,全球通用,也是旅行者入住青年旅舍的凭证。拥有会员卡,可以享受国内外国际青年旅舍住宿价格的优惠,同时部分海外青年旅舍只允许会员入住。
  30 + 成为YHA青年旅舍会员的好处:
  31 + <view>1)入住青年旅舍享受房价上的优惠;</view>
  32 + <view>2)在世界各地享有食、住、行、游、购、娱等逾3,000项优惠,如:在全球多个国际机场和车船站,凭会员卡兑换外币可免收手续费;观光、租车、购物、参团、购买车船票等均可能有折扣,折扣率高达50%。单是在澳大利亚,优惠项目便接近800种;</view>
  33 + <view>3)以优惠价格参与多项由青年旅舍举办的各类文化、旅游等方面的交流活动;</view>
  34 + <view>4)优先参与青年旅舍组织的国际交流活动。</view>
  35 +
  36 + </view>
  37 + </view>
  38 +</template>
  39 +
  40 +<script>
  41 +import app from "../../App.vue";
  42 +export default {
  43 + data(){
  44 + return{
  45 + name:'',
  46 + province_id:'',
  47 + city_id:'',
  48 + cardlist:[],
  49 + background: ['color1', 'color2', 'color3'],
  50 + indicatorDots: false,
  51 + autoplay: true,
  52 + interval: 3000,
  53 + duration: 500,
  54 + indicatorColor:'rgba(255,255,255,1)',
  55 + indicatorActiveColor:'#ffffff',
  56 + currentSwiper: 0,
  57 + imgUrls:[1,2],
  58 + vip_id:''
  59 + }
  60 + },
  61 + methods:{
  62 + getcardmsg(){
  63 + var that = this
  64 + var url = "vip/getVipConf"
  65 + var params = {
  66 + name:that.name,
  67 + province_id:that.name,
  68 + city_id:that.name
  69 + }
  70 + app.post(url,params,"post").then((res)=>{
  71 + console.log(res)
  72 + that.cardlist=res
  73 + }).catch((err)=>{
  74 + console.log(err)
  75 + })
  76 + },
  77 + swiperChange: function(e) {
  78 + this.currentSwiper= e.detail.current
  79 +
  80 + },
  81 + buycard(e){
  82 + var that = this
  83 + let vip_id=e.currentTarget.dataset.id;
  84 + console.log(vip_id)
  85 + var url = "vip/buyVip"
  86 + var header = {
  87 + // token:uni.getStorageSync('token'),
  88 +
  89 + }
  90 + var params = {
  91 + token:uni.getStorageSync('token'),
  92 + vip_id:vip_id
  93 + }
  94 + console.log(params)
  95 + app.post(url,params,"post").then((res)=>{
  96 + console.log(res)
  97 + that.payment(res)
  98 + }).catch((err)=>{
  99 + console.log(err)
  100 + })
  101 + },
  102 + payment(res) {
  103 + let that = this;
  104 + var timeStamp = res.timeStamp.toString();
  105 + // console.log(timeStamp);
  106 + wx.requestPayment({
  107 + timeStamp: timeStamp,
  108 + nonceStr: res.nonceStr,
  109 + package: res.package,
  110 + signType: res.signType,
  111 + paySign: res.paySign,
  112 + success: function(res) {
  113 + console.log(res)
  114 + wx.navigateTo({
  115 + url: '/pages/orderbox/orderbox?index=' + 0
  116 + })
  117 + },
  118 + fail: function(res) {
  119 + console.log(123);
  120 + console.log(res);
  121 + }
  122 + })
  123 + },
  124 + },
  125 + onLoad(){
  126 + this.getcardmsg()
  127 + }
  128 +}
  129 +</script>
  130 +
  131 +<style lang="less">
  132 +.content{
  133 +
  134 + .bg{
  135 + width: 750rpx;
  136 + height: 292rpx;
  137 + }
  138 + .card{
  139 + width: 636rpx;
  140 + height: 360rpx;
  141 + position: absolute;
  142 + top: 26rpx;
  143 + left: 50%;
  144 + transform: translate(-50%);
  145 + }
  146 + .cardText{
  147 + width: 636rpx;
  148 + height: 360rpx;
  149 + position: absolute;
  150 + top: 26rpx;
  151 + left: 50%;
  152 + transform: translate(-50%);
  153 + padding: 62rpx 40rpx;
  154 + box-sizing: border-box;
  155 + z-index: 777;
  156 + .title{
  157 + color:rgba(130,75,59,1);
  158 + font-size: 50rpx;
  159 +
  160 + }
  161 + .money{
  162 + color:rgba(130,75,59,1);
  163 + font-size: 36rpx;
  164 + }
  165 + .time{
  166 + color:rgba(130,75,59,1);
  167 + font-size: 24rpx;
  168 + margin-top: 70rpx;
  169 + }
  170 + .btn{
  171 + width:206rpx;
  172 + height:60rpx;
  173 + background:rgba(130,75,59,1);
  174 + opacity:1;
  175 + border-radius:42rpx;
  176 + color:rgba(255,255,255,1);
  177 + font-size:32rpx;
  178 + text-align: center;
  179 + line-height: 60rpx;
  180 + position: absolute;
  181 + right: 26rpx;
  182 + bottom: 52rpx;
  183 + .icon{
  184 + width: 15rpx;
  185 + height: 27rpx;
  186 + margin-left: 10rpx;
  187 + }
  188 + }
  189 + .dots{
  190 + position: absolute;
  191 + bottom: 10rpx;
  192 + left: 50%;
  193 + transform: translate(-50%);
  194 + width: 50rpx;
  195 + height: 10rpx;
  196 + z-index: 999;
  197 + display: flex;
  198 + justify-content: space-between;
  199 + .dot{
  200 + width: 10rpx;
  201 + height: 10rpx;
  202 + background-color: #fff;
  203 + border-radius:12rpx;
  204 + }
  205 + .active{
  206 + width: 30rpx;
  207 + height: 10rpx;
  208 + }
  209 + }
  210 + .big{
  211 + width: 24rpx;
  212 + height: 8rpx;
  213 + position: absolute;
  214 + bottom: 10rpx;
  215 + left: 298rpx;
  216 + }
  217 + .small{
  218 + width: 8rpx;
  219 + height: 8rpx;
  220 + position: absolute;
  221 + bottom: 10rpx;
  222 + left: 330rpx;
  223 + }
  224 + }
  225 + .textBox{
  226 + font-size: 24rpx;
  227 + width: 640rpx;
  228 + margin: 0 auto;
  229 + margin-top: 138rpx;
  230 + }
  231 +}
  232 +</style>
  1 +<template>
  2 + <view class="content">
  3 +
  4 + <view class="title">
  5 + <view class="history" :class="{active:active1}" @click="historyShow">浏览历史</view>
  6 + <view class="cellect" :class="{active:active2}" @click="cellectShow">我的收藏</view>
  7 + </view>
  8 + <view class="historyBox" v-if="isHistoryShow">
  9 + <view class="liulan">
  10 + <view class="liulantitle">浏览历史</view>
  11 + <view class="del">清空</view>
  12 + <!-- <view class="del">完成</view> -->
  13 + </view>
  14 + <view class="mateitem" v-for="(item,index) in historylist" :key="index">
  15 + <view class="contentBox">
  16 + <image class="photo" src="../../static/logo_img@2x.png"></image>
  17 + <view class="cont">
  18 + <view class="title">红色的战旗</view>
  19 +
  20 + <view class="fen">就读体验</view>
  21 + </view>
  22 + <view class="right">
  23 + <view class="text">已关注</view>
  24 + </view>
  25 + <view class="txt">班主任用“心”战“疫” 全力做好学生防疫工作</view>
  26 + </view>
  27 + </view>
  28 + <view class="nodata" v-if="historylist.length==0">暂无数据</view>
  29 +
  30 +
  31 + </view>
  32 +
  33 + <!-- 我的收藏 -->
  34 + <view class="cellectBox" v-else>
  35 + <view class="liulan">
  36 + <view class="liulantitle">我的收藏</view>
  37 + <view class="del" @click="change2" v-if="isdel">完成</view>
  38 + <view class="del" @click="change" v-else>编辑</view>
  39 + </view>
  40 + <view class="mateitem" v-for="(item,index) in cellectlist" :key="index">
  41 + <image class="delBtn" src="../../static/shanchu_icon@2x.png" v-if="isdel"></image>
  42 + <view class="contentBox" :style="{width:width}">
  43 + <image class="photo" src="../../static/logo_img@2x.png"></image>
  44 + <view class="cont">
  45 + <view class="title">红色的战旗</view>
  46 + <view class="fen">就读体验</view>
  47 + </view>
  48 + <view class="right">
  49 + <view class="text">已关注</view>
  50 + </view>
  51 + <view class="txt">班主任用“心”战“疫” 全力做好学生防疫工作</view>
  52 + </view>
  53 +
  54 + </view>
  55 + <view class="nodata" v-if="cellectlist.length==0">暂无数据</view>
  56 +
  57 + </view>
  58 + </view>
  59 +</template>
  60 +
  61 +<script>
  62 +import app from "../../App.vue";
  63 +export default {
  64 + data(){
  65 + return{
  66 + active1:true,
  67 + active2:false,
  68 + isHistoryShow:true,
  69 + isdel:false,
  70 + width:"660rpx",
  71 + page:1,
  72 + size:10,
  73 + cellectlist:[],
  74 + historylist:[]
  75 + }
  76 + },
  77 + methods:{
  78 + historyShow(){
  79 + this.active1=true,
  80 + this.active2=false,
  81 + this.isHistoryShow=true
  82 + },
  83 + cellectShow(){
  84 + this.isHistoryShow=false,
  85 + this.active2=true,
  86 + this.active1=false
  87 + },
  88 + change(){
  89 + this.isdel=true
  90 + this.width="620rpx"
  91 +
  92 + },
  93 + change2(){
  94 + this.isdel=false
  95 + this.width="660rpx"
  96 + },
  97 + getMyCellect(){
  98 + var that = this
  99 + var url = "article/getMyLikeArticle"
  100 + var token = uni.getStorageSync('token')
  101 + var params = {
  102 + token:token,
  103 + page:that.page,
  104 + size:that.size
  105 + }
  106 + app.post(url,params,"get").then((res)=>{
  107 + console.log(res)
  108 + that.cellectlist=res
  109 + }).catch((err)=>{
  110 + console.log(err)
  111 + })
  112 + },
  113 + gethistory(){
  114 + var that = this
  115 + var url = "article/getLookArticleList"
  116 + var token = uni.getStorageSync('token')
  117 + var params = {
  118 + token:token,
  119 + page:that.page,
  120 + size:that.size
  121 + }
  122 + app.post(url,params,"get").then((res)=>{
  123 + console.log(res)
  124 + that.historylist=res
  125 + }).catch((err)=>{
  126 + console.log(err)
  127 + })
  128 + }
  129 + },
  130 + onLoad(){
  131 + this.getMyCellect()
  132 + }
  133 +
  134 +}
  135 +</script>
  136 +
  137 +<style lang="less">
  138 +.content{
  139 + background-color: #F9F9F9;
  140 + .nodata{
  141 + font-size: 28rpx;
  142 + text-align: center;
  143 + }
  144 + .title{
  145 + background-color: #fff;
  146 + display: flex;
  147 + .history,.cellect{
  148 + width: 50%;
  149 + text-align: center;
  150 + font-size:28rpx;
  151 + padding: 24rpx 0;
  152 + }
  153 + .active{
  154 + background: url("../../static/xuanzhong_icon@2x.png") no-repeat;
  155 + background-size: 60rpx 12rpx;
  156 + background-position: 156rpx 70rpx;
  157 + color: rgba(5,132,157,1);
  158 + }
  159 + }
  160 + .liulan{
  161 + display: flex;
  162 + font-size:32rpx;
  163 + width: 686rpx;
  164 + margin: 0 auto;
  165 + justify-content: space-between;
  166 + padding: 30rpx 0;
  167 + .liulantitle{
  168 + color:rgba(45,85,117,1);
  169 + }
  170 + .del{
  171 + font-size:24rpx;
  172 + }
  173 + }
  174 + .mateitem{
  175 + display: flex;
  176 + align-items: center;
  177 + width:686rpx;
  178 + // height:172rpx;
  179 + background:rgba(255,255,255,1);
  180 + opacity:1;
  181 + border-radius:20rpx;
  182 + margin: 0 auto;
  183 + background-color: #fff;
  184 + padding: 24rpx 0;
  185 + // box-sizing: border-box;
  186 + margin-bottom: 24rpx;
  187 + .delBtn{
  188 + width: 28rpx;
  189 + height: 28rpx;
  190 + // position: absolute;
  191 + // top: 50%;
  192 + // transform: translateY(-50%);
  193 + // left: 28rpx;
  194 + margin-left: 26rpx;
  195 + }
  196 + .contentBox{
  197 + display: flex;
  198 + // align-items: center;
  199 + position: relative;
  200 + flex-wrap: wrap;
  201 + margin-left: 26rpx;
  202 + width: 660rpx;
  203 + .photo{
  204 + width: 68rpx;
  205 + height: 68rpx;
  206 + margin-right: 26rpx;
  207 + margin-top: 6rpx;
  208 + }
  209 + .cont{
  210 + .title{
  211 + color:rgba(61,68,77,1);
  212 + font-size: 24rpx;
  213 + }
  214 +
  215 + .fen{
  216 + font-size: 24rpx;
  217 + color:rgba(140,145,152,1);
  218 + margin-top: 4rpx;
  219 + }
  220 + }
  221 + .right{
  222 + width:118rpx;
  223 + height:44rpx;
  224 + border:2rpx solid rgba(189,196,206,1);
  225 + opacity:1;
  226 + border-radius:40rpx;
  227 + position: absolute;
  228 + right: 26rpx;
  229 + top: 32rpx;
  230 + .text{
  231 + color:rgba(189,196,206,1);
  232 + text-align: center;
  233 + line-height: 44rpx;
  234 + font-size:24rpx;
  235 + }
  236 + }
  237 + .txt{
  238 + // width: 600rpx;
  239 + font-size:28rpx;
  240 + margin-top: 24rpx;
  241 + }
  242 + }
  243 +
  244 +
  245 + }
  246 +}
  247 +</style>
  1 +<template>
  2 + <view class="content">
  3 + <view class="title">
  4 + <view class="mine" :class="{active:active3}" @click="mineShow">我的发布</view>
  5 + <view class="history" :class="{active:active1}" @click="historyShow">浏览历史</view>
  6 + <view class="cellect" :class="{active:active2}" @click="cellectShow">我的收藏</view>
  7 + </view>
  8 + <view class="mineBox" v-if="isMineShow==true&&isHistoryShow==false">
  9 + <view class="minetop">
  10 + <view class="mineTitle">我的发布</view>
  11 + <view class="del" @click="edit" v-if="isedit==false">编辑</view>
  12 + <view class="del" @click="editok" v-if="isedit==true">完成</view>
  13 + <!-- <view class="del">完成</view> -->
  14 + </view>
  15 + <view class="item" v-for="(item,index) in articlelist" :key="index">
  16 + <image class="icon" src="../../static/shanchu_icon@2x.png" v-if="isedit" @click="delarcial(item,index)"></image>
  17 + <view class="cont" :style="{width:width}" @click="toarticl" :data-id="item.id">
  18 + <view class="rowOne">{{item.article_type_name}}</view>
  19 + <view class="rowTwo">{{item.title}}</view>
  20 + <view class="rowThree">{{item.des_content}}</view>
  21 + </view>
  22 + </view>
  23 + <view class="nodata" v-if="articlelist.length==0">暂无数据</view>
  24 + </view>
  25 + <view class="historyBox" v-if="isHistoryShow==true&&isMineShow==false">
  26 + <view class="liulan">
  27 + <view class="liulantitle">浏览历史</view>
  28 + <view class="del" @click="delhistory">清空</view>
  29 + <!-- <view class="del">完成</view> -->
  30 + </view>
  31 + <view class="mateitem" v-for="(item,index) in historylist" :key="index">
  32 + <view class="contentBox">
  33 + <image class="photo" src="../../static/logo_img@2x.png"></image>
  34 + <view class="cont">
  35 + <view class="title">红色的战旗</view>
  36 +
  37 + <view class="fen">就读体验</view>
  38 + </view>
  39 + <view class="right">
  40 + <view class="text">已关注</view>
  41 + </view>
  42 + <view class="txt">班主任用“心”战“疫” 全力做好学生防疫工作</view>
  43 + </view>
  44 + </view>
  45 + <view class="nodata" v-if="historylist.length==0">暂无消息</view>
  46 +
  47 + </view>
  48 + <view class="cellcetBox" v-if="isHistoryShow==false&&isMineShow==false">
  49 + <view class="liulan">
  50 + <view class="liulantitle">我的收藏</view>
  51 + <view class="del" @click="change2" v-if="isdel">完成</view>
  52 + <view class="del" @click="change" v-else>编辑</view>
  53 + </view>
  54 + <view class="mateitem" v-for="(item,index) in cellectlist" :key="index">
  55 + <image class="delBtn" src="../../static/shanchu_icon@2x.png" v-if="isdel"></image>
  56 + <view class="contentBox" :style="{width:width2}">
  57 + <image class="photo" src="../../static/logo_img@2x.png"></image>
  58 + <view class="cont">
  59 + <view class="title">{{item.nickname}}</view>
  60 +
  61 + <view class="fen">{{item.title}}</view>
  62 + </view>
  63 + <view class="right">
  64 + <view class="text">已关注</view>
  65 + </view>
  66 + <view class="txt">{{item.des_content}}</view>
  67 + </view>
  68 + </view>
  69 + <view class="nodata" v-if="cellectlist.length==0">暂无数据</view>
  70 +
  71 + </view>
  72 + </view>
  73 +</template>
  74 +
  75 +<script>
  76 +import app from "../../App.vue";
  77 +export default {
  78 + data(){
  79 + return{
  80 + active3:true,
  81 + active1:false,
  82 + active2:false,
  83 + isHistoryShow:false,
  84 + isMineShow:true,
  85 + isdel:false,
  86 + isedit:false,
  87 + width:'686rpx',
  88 + width2:'660rpx',
  89 + page:1,
  90 + size:10,
  91 + articlelist:[],
  92 + historylist:[],
  93 + cellectlist:[]
  94 + }
  95 + },
  96 + methods:{
  97 + historyShow(){
  98 + this.active1=true,
  99 + this.active2=false,
  100 + this.isHistoryShow=true
  101 + this.isMineShow=false,
  102 + this.active3=false
  103 + },
  104 + cellectShow(){
  105 + this.isHistoryShow=false,
  106 + this.active2=true,
  107 + this.active1=false,
  108 + this.isMineShow=false,
  109 + this.active3=false
  110 + },
  111 + mineShow(){
  112 + this.active3=true,
  113 + this.active1=false,
  114 + this.active2=false,
  115 + this.isMineShow=true,
  116 + this.isHistoryShow=false
  117 + },
  118 + edit(){
  119 + this.isedit=true,
  120 + this.width="580rpx"
  121 + },
  122 + editok(){
  123 + this.isedit=false,
  124 + this.width="686rpx"
  125 + },
  126 + change(){
  127 + this.isdel=true
  128 + this.width="620rpx"
  129 +
  130 + },
  131 + change2(){
  132 + this.isdel=false
  133 + this.width="660rpx"
  134 + },
  135 + getMyArticle(){
  136 + var that = this
  137 + var url = "article/getMyArticle"
  138 + var token = uni.getStorageSync('token')
  139 + var params = {
  140 + token:token,
  141 + page:that.page,
  142 + size:that.size
  143 + }
  144 + app.post(url,params,"get").then((res)=>{
  145 + console.log(res)
  146 + that.articlelist=res
  147 + }).catch((err)=>{
  148 + console.log(err)
  149 + })
  150 + },
  151 + gethistory(){
  152 + var that = this
  153 + var url = "article/getLookArticleList"
  154 + var token = uni.getStorageSync('token')
  155 + var params = {
  156 + token:token
  157 + }
  158 + app.post(url,params,"get").then((res)=>{
  159 + that.historylist=res
  160 + console.log(res)
  161 + }).catch((err)=>{
  162 + console.log(err)
  163 + })
  164 + },
  165 + delhistory(){
  166 + var that = this
  167 + var url = "article/delLookArticle"
  168 + var token = uni.getStorageSync('token')
  169 + var params = {
  170 + token:token
  171 + }
  172 + app.post(url,params,"post").then((res)=>{
  173 + that.historylist=res
  174 + console.log(res)
  175 + uni.showToast({
  176 + title:'浏览记录已清空'
  177 + })
  178 + }).catch((err)=>{
  179 + console.log(err)
  180 + })
  181 + },
  182 + getMyCellect(){
  183 + var that = this
  184 + var url = "article/getMyLikeArticle"
  185 + var token = uni.getStorageSync('token')
  186 + var params = {
  187 + token:token,
  188 + page:that.page,
  189 + size:that.size
  190 + }
  191 + app.post(url,params,"get").then((res)=>{
  192 + console.log(res)
  193 + that.cellectlist=res
  194 + }).catch((err)=>{
  195 + console.log(err)
  196 + })
  197 + },
  198 + toarticl(e){
  199 + var id = e.currentTarget.dataset.id
  200 + uni.navigateTo({
  201 + url:'../school/article?article_id='+id
  202 + })
  203 + },
  204 + delarcial(item,index){
  205 + var that = this
  206 + var url = "article/delArticle"
  207 + var params = {
  208 + token:uni.getStorageSync('token'),
  209 + article_id:item.id
  210 + }
  211 + app.post(url,params,"post").then((res)=>{
  212 + console.log(res)
  213 + that.articlelist.splice(index, 1) 
  214 + uni.showToast({
  215 + title:'删除成功',
  216 + icon:'none'
  217 + })
  218 + }).catch((err)=>{
  219 + console.log(err)
  220 + })
  221 + }
  222 + },
  223 + onLoad(){
  224 + this.getMyArticle()
  225 + this.gethistory()
  226 + this.getMyCellect()
  227 + }
  228 +
  229 +}
  230 +</script>
  231 +
  232 +<style lang="less">
  233 + .content{
  234 + background:rgba(249,249,249,1);
  235 + height: 100vh;
  236 + // padding: 32rpx;
  237 + .nodata{
  238 + text-align: center;
  239 + font-size: 28rpx;
  240 + }
  241 + .title{
  242 + background-color: #fff;
  243 + display: flex;
  244 + .history,.cellect,.mine{
  245 + width: 33%;
  246 + text-align: center;
  247 + font-size:28rpx;
  248 + padding: 24rpx 0;
  249 + }
  250 + .active{
  251 + background: url("../../static/xuanzhong_icon@2x.png") no-repeat;
  252 + background-size: 60rpx 12rpx;
  253 + background-position: 95rpx 70rpx;
  254 + color: rgba(5,132,157,1);
  255 + }
  256 + }
  257 + .minetop{
  258 + display: flex;
  259 + font-size:32rpx;
  260 + width: 686rpx;
  261 + margin: 0 auto;
  262 + justify-content: space-between;
  263 + padding: 30rpx 0;
  264 + .mineTitle{
  265 + color:rgba(45,85,117,1);
  266 + }
  267 + .del{
  268 + font-size:24rpx;
  269 + }
  270 + }
  271 + .item{
  272 + width: 686rpx;
  273 + background-color: #fff;
  274 + margin: 0 auto;
  275 + border-radius:20rpx;
  276 + padding: 20rpx 30rpx;
  277 + box-sizing: border-box;
  278 + margin-bottom: 14rpx;
  279 + display: flex;
  280 + align-items: center;
  281 + .cont{
  282 + .rowOne{
  283 + font-size:24rpx;
  284 + color:rgba(140,145,152,1);
  285 + }
  286 + .rowTwo{
  287 + font-size:28rpx;
  288 + color:rgba(61,68,77,1);
  289 + margin-top: 16rpx;
  290 + }
  291 + .rowThree{
  292 + font-size:24rpx;
  293 + color:rgba(140,145,152,1);
  294 + margin-top: 4rpx;
  295 + height: 74rpx;
  296 + overflow: hidden;
  297 + }
  298 + }
  299 + .icon{
  300 + width: 28rpx;
  301 + height: 28rpx;
  302 + margin-right: 26rpx;
  303 + }
  304 + }
  305 + .liulan{
  306 + display: flex;
  307 + font-size:32rpx;
  308 + width: 686rpx;
  309 + margin: 0 auto;
  310 + justify-content: space-between;
  311 + padding: 30rpx 0;
  312 + .liulantitle{
  313 + color:rgba(45,85,117,1);
  314 + }
  315 + .del{
  316 + font-size:24rpx;
  317 + }
  318 + }
  319 + .mateitem{
  320 + display: flex;
  321 + align-items: center;
  322 + width:686rpx;
  323 + // height:172rpx;
  324 + background:rgba(255,255,255,1);
  325 + opacity:1;
  326 + border-radius:20rpx;
  327 + margin: 0 auto;
  328 + background-color: #fff;
  329 + padding: 24rpx 0;
  330 + // box-sizing: border-box;
  331 + margin-bottom: 24rpx;
  332 + .delBtn{
  333 + width: 28rpx;
  334 + height: 28rpx;
  335 + // position: absolute;
  336 + // top: 50%;
  337 + // transform: translateY(-50%);
  338 + // left: 28rpx;
  339 + margin-left: 26rpx;
  340 + }
  341 + .contentBox{
  342 + display: flex;
  343 + // align-items: center;
  344 + position: relative;
  345 + flex-wrap: wrap;
  346 + margin-left: 26rpx;
  347 + width: 660rpx;
  348 + .photo{
  349 + width: 68rpx;
  350 + height: 68rpx;
  351 + margin-right: 26rpx;
  352 + margin-top: 6rpx;
  353 + }
  354 + .cont{
  355 + .title{
  356 + color:rgba(61,68,77,1);
  357 + font-size: 24rpx;
  358 + }
  359 +
  360 + .fen{
  361 + font-size: 24rpx;
  362 + color:rgba(140,145,152,1);
  363 + margin-top: 4rpx;
  364 + }
  365 + }
  366 + .right{
  367 + width:118rpx;
  368 + height:44rpx;
  369 + border:2rpx solid rgba(189,196,206,1);
  370 + opacity:1;
  371 + border-radius:40rpx;
  372 + position: absolute;
  373 + right: 26rpx;
  374 + top: 32rpx;
  375 + .text{
  376 + color:rgba(189,196,206,1);
  377 + text-align: center;
  378 + line-height: 44rpx;
  379 + font-size:24rpx;
  380 + }
  381 + }
  382 + .txt{
  383 + // width: 600rpx;
  384 + font-size:28rpx;
  385 + margin-top: 24rpx;
  386 + }
  387 + }
  388 +
  389 +
  390 + }
  391 + }
  392 +</style>
  1 +<template>
  2 + <view class="content">
  3 + <image class="bg" src="../../static/bg_img2.png"></image>
  4 + <image class="photo" :src="token=='' ? '../../static/touxiang_img@2x.png' : userinfolist.head_image"></image>
  5 + <view class="title">{{userinfolist.nickname}}</view>
  6 + <view class="bannerBox" @click="toPubArticle">
  7 + <image class="banner" src="../../static/fabuwenzhang_img@2x.png"></image>
  8 + <view class="textBtn">发布文章<image class="rBtn" src="../../static/dizhi_btn@2x2.png"></image></view>
  9 + </view>
  10 +
  11 + <view class="item" @click="togeren">
  12 + <view class="name"><image class="icon" src="../../static/8_icon@2x.png"></image>个人信息</view>
  13 + <image class="right" src="../../static/dizhi_btn@2x.png"></image>
  14 + </view>
  15 +
  16 + <view class="item" @click="tocollegeCellect">
  17 + <view class="name"><image class="icon" src="../../static/7_icon@2x.png"></image>我的文章</view>
  18 + <image class="right" src="../../static/dizhi_btn@2x.png"></image>
  19 + </view>
  20 +
  21 + <view class="item" @click="tofollowPeople">
  22 + <view class="name"><image class="icon" src="../../static/6_icon@2x.png"></image>关注的人</view>
  23 + <image class="right" src="../../static/dizhi_btn@2x.png"></image>
  24 + </view>
  25 +
  26 + <view class="item" @click="tomywallet">
  27 + <view class="name"><image class="icon" src="../../static/5_icon@2x.png"></image>我的钱包</view>
  28 + <image class="right" src="../../static/dizhi_btn@2x.png"></image>
  29 + </view>
  30 +
  31 + <view class="item" @click="tomycomment">
  32 + <view class="name"><image class="icon" src="../../static/4_icon@2x.png"></image>我的留言</view>
  33 + <image class="right" src="../../static/dizhi_btn@2x.png"></image>
  34 + </view>
  35 + <!-- <tab></tab> -->
  36 + <view class="collegefooter" v-if="type == 2">
  37 + <view class="teacherfootitem" @click="footerselChange" :data-id="2" :data-url="'/pages/schoolmate/schoolmate?type='+2">
  38 + <view class="teacherfootitemtop">
  39 + <image :src="footersel==2?'/static/zhaoxiaoyou_icon@2x2.png':'/static/zhaoxiaoyou_icon@2x.png'"></image>
  40 + </view>
  41 + <view class="teacherfootname" :class="footersel==2?'selactive':''">找校友</view>
  42 + </view>
  43 + <view class="teacherfootitem" @click="footerselChange" :data-id="3" :data-url="'/pages/homePage/homePage?type='+2">
  44 + <view class="teacherfootitemtop">
  45 + <image :src="footersel==3?'/static/wodezhuye_icon@2x2.png':'/static/wodezhuye_icon@2x.png'"></image>
  46 + </view>
  47 + <view class="teacherfootname" :class="footersel==3?'selactive':''">我的主页</view>
  48 + </view>
  49 + </view>
  50 + </view>
  51 +</template>
  52 +
  53 +<script>
  54 +import app from "../../App.vue";
  55 +export default {
  56 +
  57 +data(){
  58 + return{
  59 + currentTabIndex: 2,
  60 + footersel:3,
  61 + type:"",
  62 + userinfolist:{},
  63 + token:''
  64 + }
  65 +},
  66 +methods:{
  67 + toPubArticle(){
  68 + wx.navigateTo({
  69 + url:"./pubArticle"
  70 + })
  71 + },
  72 + getuserinfo(){
  73 + var that = this
  74 + var url = "student/getMyInfo"
  75 + var token = uni.getStorageSync('token')
  76 + var params = {
  77 + token:token
  78 + }
  79 + app.post(url,params,"get").then((res)=>{
  80 + console.log(res)
  81 + that.userinfolist=res
  82 + }).catch((err)=>{
  83 + console.log(err)
  84 + })
  85 + },
  86 + // 底部导航跳转
  87 + footerselChange(e){
  88 + let url=e.currentTarget.dataset.url;
  89 + console.log(url)
  90 + uni.redirectTo({
  91 +
  92 + url:url
  93 + })
  94 + },
  95 + togeren(){
  96 + if(uni.getStorageSync('token')==''){
  97 + uni.showToast({
  98 + title:"请登陆后操作",
  99 + icon:"none"
  100 + })
  101 + setTimeout(() => {
  102 + uni.navigateTo({
  103 + url:'../register/register?istoken='+1
  104 + })
  105 + }, 1500);
  106 + }else{
  107 + wx.navigateTo({
  108 + url:'./collegegerencenter'
  109 + })
  110 + }
  111 + },
  112 + tocollegeCellect(){
  113 + if(uni.getStorageSync('token')==''){
  114 + uni.showToast({
  115 + title:"请登陆后操作",
  116 + icon:"none"
  117 + })
  118 + setTimeout(() => {
  119 + uni.navigateTo({
  120 + url:'../register/register?istoken='+1
  121 + })
  122 + }, 1500);
  123 + }else{
  124 + wx.navigateTo({
  125 + url:'./collegeCellect'
  126 + })
  127 + }
  128 + },
  129 + tofollowPeople(){
  130 + if(uni.getStorageSync('token')==''){
  131 + uni.showToast({
  132 + title:"请登陆后操作",
  133 + icon:"none"
  134 + })
  135 + setTimeout(() => {
  136 + uni.navigateTo({
  137 + url:'../register/register?istoken='+1
  138 + })
  139 + }, 1500);
  140 + }else{
  141 + wx.navigateTo({
  142 + url:'./followPeople'
  143 + })
  144 + }
  145 + },
  146 + tomywallet(){
  147 + if(uni.getStorageSync('token')==''){
  148 + uni.showToast({
  149 + title:"请登陆后操作",
  150 + icon:"none"
  151 + })
  152 + setTimeout(() => {
  153 + uni.navigateTo({
  154 + url:'../register/register?istoken='+1
  155 + })
  156 + }, 1500);
  157 + }else{
  158 + wx.navigateTo({
  159 + url:'./mywallet'
  160 + })
  161 + }
  162 + },
  163 + tomycomment(){
  164 + if(uni.getStorageSync('token')==''){
  165 + uni.showToast({
  166 + title:"请登陆后操作",
  167 + icon:"none"
  168 + })
  169 + setTimeout(() => {
  170 + uni.navigateTo({
  171 + url:'../register/register?istoken='+1
  172 + })
  173 + }, 1500);
  174 + }else{
  175 + wx.navigateTo({
  176 + url:'./mycomment'
  177 + })
  178 + }
  179 + }
  180 +},
  181 +onLoad(options){
  182 + console.log(options.type)
  183 + var type=options.type
  184 + this.type=type
  185 +
  186 + this.token=uni.getStorageSync('token')
  187 + },
  188 + onShow(){
  189 + this.getuserinfo()
  190 + }
  191 +}
  192 +</script>
  193 +
  194 +<style lang="less">
  195 +.content{
  196 + text-align: center;
  197 + color:rgba(6,18,30,1);
  198 + .bg{
  199 + width: 750rpx;
  200 + height: 154rpx;
  201 + }
  202 + .photo{
  203 + width: 136rpx;
  204 + height: 136rpx;
  205 + position: absolute;
  206 + top: 52rpx;
  207 + left: 50%;
  208 + transform: translate(-50%);
  209 + }
  210 + .title{
  211 + margin-top: 66rpx;
  212 + }
  213 + .bannerBox{
  214 + position: relative;
  215 + margin: 0 auto;
  216 + margin-top: 78rpx;
  217 + margin-bottom: 30rpx;
  218 + width: 686rpx;
  219 + height: 140rpx;
  220 + .banner{
  221 + width: 686rpx;
  222 + height: 140rpx;
  223 + }
  224 + .textBtn{
  225 + position: absolute;
  226 + top: 50%;
  227 + transform: translateY(-50%);
  228 + left: 72rpx;
  229 + color: #fff;
  230 + .rBtn{
  231 + width: 11rpx;
  232 + height: 20rpx;
  233 + margin-left: 18rpx;
  234 + }
  235 + }
  236 + }
  237 +
  238 + .item{
  239 + display: flex;
  240 + align-items: center;
  241 + justify-content: space-between;
  242 + width: 686rpx;
  243 + margin: 0 auto;
  244 + padding: 32rpx 0;
  245 + border-bottom: 1rpx solid rgba(238,238,238,1);
  246 + .icon{
  247 + width: 36rpx;
  248 + height: 36rpx;
  249 + margin-right: 12rpx;
  250 + }
  251 + .name{
  252 + font-size: 28rpx;
  253 + display: flex;
  254 + align-items: center;
  255 + }
  256 + .right{
  257 + width: 10rpx;
  258 + height: 19rpx;
  259 + }
  260 + }
  261 +}
  262 +</style>
  1 +<template>
  2 + <view class="content">
  3 + <view class="card">
  4 + <view class="item">
  5 + <view class="name">姓名</view>
  6 + <input v-model="username" type="text" class="cont" :placeholder="userinfolist.nickname=='undefinde'? '' : userinfolist.nickname" placeholder-style="text-align: right;font-size:28rpx;" style="width:146rpx;text-align: right">
  7 + <!-- <view class="cont">爱学习的王笑笑</view> -->
  8 + </view>
  9 + <!-- <view class="item">
  10 + <view class="name">邮箱</view>
  11 + <input v-model="email" type="text" class="cont" placeholder="{{userinfolist.email}}" placeholder-style="text-align: right;font-size:28rpx;" style="width:220rpx;text-align: right">
  12 + </view> -->
  13 + <view class="item" style="border:none">
  14 + <view class="name">头像</view>
  15 + <image class="photo" @click="upload" :src="isUpload ? image : userinfolist.head_image"></image>
  16 + </view>
  17 +
  18 + </view>
  19 + <view class="title">高中信息</view>
  20 + <view class="card">
  21 + <view class="item">
  22 + <view class="name">高中</view>
  23 + <!-- <input type="text" class="cont" placeholder="爱学习的王笑笑" placeholder-style="text-align: right;font-size:28rpx;color:#BDC4CE" style="width:200rpx"> -->
  24 + <view class="cont">
  25 + {{userinfolist.school_info.name}}
  26 + <image class="icon" src="../../static/dizhi_btn@2x2.png"></image>
  27 + </view>
  28 + </view>
  29 + <view class="item">
  30 + <view class="name">毕业年份</view>
  31 + <!-- <input type="text" class="cont" placeholder="爱学习的王笑笑" placeholder-style="text-align: right;font-size:28rpx;color:#BDC4CE" style="width:200rpx"> -->
  32 + <view class="cont">
  33 + {{userinfolist.endtime}}
  34 + <image class="icon" src="../../static/dizhi_btn@2x2.png"></image>
  35 + </view>
  36 + </view>
  37 + <view class="item">
  38 + <view class="name">高考学科</view>
  39 + <!-- <input type="text" class="cont" placeholder="爱学习的王笑笑" placeholder-style="text-align: right;font-size:28rpx;color:#BDC4CE" style="width:200rpx"> -->
  40 + <view class="cont">
  41 + 语数外
  42 + <image class="icon" src="../../static/dizhi_btn@2x2.png"></image>
  43 + </view>
  44 + </view>
  45 + <view class="item">
  46 + <view class="name">选考科目</view>
  47 + <!-- <input type="text" class="cont" placeholder="爱学习的王笑笑" placeholder-style="text-align: right;font-size:28rpx;color:#BDC4CE" style="width:200rpx"> -->
  48 + <view class="cont">
  49 + {{userinfolist.subject_list[0].name}}
  50 + <image class="icon" src="../../static/dizhi_btn@2x2.png"></image>
  51 + </view>
  52 + </view>
  53 + <view class="item">
  54 + <view class="name">升学方式</view>
  55 + <!-- <input type="text" class="cont" placeholder="爱学习的王笑笑" placeholder-style="text-align: right;font-size:28rpx;color:#BDC4CE" style="width:200rpx"> -->
  56 + <view class="cont">
  57 + {{userinfolist.up_info.name}}
  58 + <image class="icon" src="../../static/dizhi_btn@2x2.png"></image>
  59 + </view>
  60 + </view>
  61 + </view>
  62 + <view class="title">大学信息</view>
  63 + <view class="card">
  64 + <view class="item">
  65 + <view class="name">就读大学</view>
  66 + <!-- <input type="text" class="cont" placeholder="爱学习的王笑笑" placeholder-style="text-align: right;font-size:28rpx;color:#BDC4CE" style="width:200rpx"> -->
  67 + <view class="cont">
  68 + {{userinfolist.university_info.name}}
  69 + <image class="icon" src="../../static/dizhi_btn@2x2.png"></image>
  70 + </view>
  71 + </view>
  72 + <view class="item">
  73 + <view class="name">所属学院</view>
  74 + <!-- <input type="text" class="cont" placeholder="爱学习的王笑笑" placeholder-style="text-align: right;font-size:28rpx;color:#BDC4CE" style="width:200rpx"> -->
  75 + <view class="cont">
  76 + {{userinfolist.college_info.name}}
  77 + <image class="icon" src="../../static/dizhi_btn@2x2.png"></image>
  78 + </view>
  79 + </view>
  80 + <view class="item">
  81 + <view class="name">就读专业</view>
  82 + <!-- <input type="text" class="cont" placeholder="爱学习的王笑笑" placeholder-style="text-align: right;font-size:28rpx;color:#BDC4CE" style="width:200rpx"> -->
  83 + <view class="cont">
  84 + {{userinfolist.graduated_info.name}}
  85 + <image class="icon" src="../../static/dizhi_btn@2x2.png"></image>
  86 + </view>
  87 + </view>
  88 +
  89 +
  90 + </view>
  91 + <view class="btn" @click="update">保存</view>
  92 + </view>
  93 +</template>
  94 +
  95 +<script>
  96 +import app from "../../App.vue";
  97 +export default {
  98 +data(){
  99 + return{
  100 + username:'',
  101 + image:'',
  102 + image2:'',
  103 + isUpload:false,
  104 + userinfolist:[],
  105 + school_id:'',
  106 + name:'',
  107 + email:'',
  108 + date: '2020',
  109 + isDateShow:false
  110 + }
  111 +},
  112 +methods:{
  113 + getuserinfo(){
  114 + var that = this
  115 + var url = "student/getMyInfo"
  116 + var token = uni.getStorageSync('token')
  117 + var params = {
  118 + token:token
  119 + }
  120 + app.post(url,params,"get").then((res)=>{
  121 + console.log(res)
  122 + that.userinfolist=res
  123 + }).catch((err)=>{
  124 + console.log(err)
  125 + })
  126 + },
  127 + upload(){
  128 + var that = this;
  129 + uni.chooseImage({
  130 + count: 1,
  131 + sizeType: ['original', 'compressed'], //可以指定是原图还是压缩图,默认二者都有
  132 + sourceType: ['album'], //从相册选择
  133 + success: function (res) {
  134 + const tempFilePaths = res.tempFilePaths;
  135 + that.image = tempFilePaths[0];
  136 + app.upload('image',res.tempFilePaths[0],"post").then((res)=>{
  137 + // let newimage=that.image
  138 + that.image=app.globalData.imageBaseUrl+res.url
  139 + that.image2=res.url
  140 + console.log(res)
  141 + console.log(that.image)
  142 + console.log(res.url)
  143 + // newimage.push(res.url)
  144 + that.isUpload=true
  145 + }).catch((err)=>{
  146 + console.log(err)
  147 + })
  148 + // console.log("tempFilePaths[0]",tempFilePaths[0]) //能够打印出选中的图片
  149 + // console.log(res)
  150 + // that.head_image=tempFilePaths[0]
  151 + // that.iconcheck = 1;//点击后图片更改状态由0变成1
  152 + },
  153 + error : function(e){
  154 + console.log(e);
  155 + }
  156 + });
  157 + },
  158 + bindTimeChange(e){
  159 + this.date = e.target.value
  160 + },
  161 + update(){
  162 + var that = this
  163 + var url = "student/updateStudentInfo"
  164 + var token = uni.getStorageSync('token')
  165 + var params= {
  166 + token:token,
  167 + nickname:that.username=='' ? that.userinfolist.nickname : that.username,
  168 + head_image:that.image2=='' ? that.userinfolist.head_image : that.image2
  169 + }
  170 + app.post(url,params,"post").then((res)=>{
  171 + console.log(res)
  172 + res.head_image=that.image
  173 + res.nickname=that.username
  174 + uni.showToast({
  175 + title:'个人信息保存成功',
  176 + icon:'none'
  177 + })
  178 + setTimeout(() => {
  179 + uni.navigateBack()
  180 + },1500);
  181 +
  182 + }).catch((err)=>{
  183 + console.log(err)
  184 + if(err.code==0){
  185 + uni.showToast({
  186 + title:err.msg,
  187 + icon:'none'
  188 + })
  189 + }
  190 + })
  191 +
  192 + }
  193 +},
  194 +onLoad(){
  195 + this.getuserinfo()
  196 +}
  197 +}
  198 +</script>
  199 +
  200 +<style lang="less">
  201 +.content{
  202 + background-color: rgba(249,249,249,1);
  203 + padding: 32rpx 32rpx 40rpx;
  204 + // height: 100vh;
  205 + .card{
  206 + width:686rpx;
  207 + // height:428rpx;
  208 + background:rgba(255,255,255,1);
  209 + opacity:1;
  210 + border-radius:20rpx;
  211 + margin: 0 auto;
  212 +
  213 + .item{
  214 + width: 622rpx;
  215 + display: flex;
  216 + justify-content: space-between;
  217 + align-items: center;
  218 + padding: 32rpx 0;
  219 + box-sizing: border-box;
  220 + font-size: 28rpx;
  221 + margin: 0 auto;
  222 + border-bottom: 1rpx solid rgba(238,238,238,1);
  223 + .cont{
  224 + display: flex;
  225 + align-items: center;
  226 +
  227 + }
  228 + .photo{
  229 + width: 64rpx;
  230 + height: 64rpx;
  231 + border-radius: 50%;
  232 + }
  233 + .icon{
  234 + width: 11rpx;
  235 + height: 22rpx;
  236 + margin-left: 12rpx;
  237 +
  238 + }
  239 +
  240 +
  241 + }
  242 + }
  243 + .title{
  244 + color:rgba(45,85,117,1);
  245 + font-size: 32rpx;
  246 + margin-top: 44rpx;
  247 + margin-bottom: 12rpx;
  248 + }
  249 + .btn{
  250 + width:684rpx;
  251 + height:80rpx;
  252 + background:rgba(45,85,117,1);
  253 + opacity:1;
  254 + border-radius:8rpx;
  255 + color: #fff;
  256 + line-height: 80rpx;
  257 + text-align: center;
  258 + margin: 0 auto;
  259 + margin-top: 66rpx;
  260 + }
  261 +}
  262 +</style>
  1 +<template>
  2 + <view class="content">
  3 + <view class="title">
  4 + <image class="photo" :src="image"></image>
  5 + <view class="name">{{nickname}}</view>
  6 + </view>
  7 + <view class="contentBox">
  8 + <view class="comment" :style="{'margin-left:246rpx;': user_id==item.usera_id}" v-for="(item,index) in meslist" :key="index">
  9 + <span>{{item.des_content}}</span>
  10 + <view class="time">{{item.createtime}}</view>
  11 + </view>
  12 +
  13 +
  14 + </view>
  15 + <view class="inputBox">
  16 + <input type="text" class="input" v-model="des_content">
  17 + <view class="btn" @click="sendmsg">发送</view>
  18 + </view>
  19 + </view>
  20 +</template>
  21 +
  22 +<script>
  23 +import app from "../../App.vue";
  24 +export default {
  25 + data(){
  26 + return{
  27 + des_content:'',
  28 + userb_id:'',
  29 + page:1,
  30 + size:10,
  31 + meslist:[],
  32 + image:'',
  33 + nickname:'',
  34 + user_id:''
  35 + }
  36 + },
  37 + methods:{
  38 + sendmsg(){
  39 + var that = this
  40 + var url = "mes/sendMes"
  41 + var params = {
  42 + token:uni.getStorageSync('token'),
  43 + userb_id:that.userb_id,
  44 + des_content:that.des_content
  45 + }
  46 + app.post(url,params,"post").then((res)=>{
  47 + console.log(res)
  48 + that.des_content=''
  49 + }).catch((err)=>{
  50 + console.log(err)
  51 + })
  52 + },
  53 + getmeslist(){
  54 + var that = this
  55 + var url = "mes/getMesDetail"
  56 + var params = {
  57 + token:uni.getStorageSync('token'),
  58 + page:that.page,
  59 + size:that.size,
  60 + userb_id:that.userb_id
  61 + }
  62 + app.post(url,params,"get").then((res)=>{
  63 + console.log(res)
  64 + that.meslist=res
  65 + }).catch((err)=>{
  66 + console.log(err)
  67 + })
  68 + }
  69 +
  70 + },
  71 + onLoad(options){
  72 + console.log(options)
  73 + this.userb_id=options.userb_id
  74 + this.user_id=options.user_id
  75 + this.nickname=options.nickname
  76 + this.image=options.head_image
  77 + this.getmeslist()
  78 + }
  79 +
  80 +}
  81 +</script>
  82 +
  83 +<style lang="less">
  84 +.content{
  85 + background-color: #F9F9F9;
  86 + .title{
  87 + display: flex;
  88 + align-items: center;
  89 + background-color: #fff;
  90 + padding: 16rpx 32rpx;
  91 + .photo{
  92 + width: 68rpx;
  93 + height: 68rpx;
  94 + }
  95 + .name{
  96 + font-size: 28rpx;
  97 + margin-left: 18rpx;
  98 + }
  99 + }
  100 + .contentBox{
  101 + // height: 100vh;
  102 + background-color: #F9F9F9;
  103 + .right{
  104 + margin-left:246rpx;
  105 + }
  106 + .comment{
  107 + color:rgba(6,18,30,1);
  108 + font-size: 24rpx;
  109 + width:472rpx;
  110 +
  111 + background:rgba(255,255,255,1);
  112 + padding: 22rpx 18rpx;
  113 + box-sizing: border-box;
  114 + margin: 56rpx 32rpx;
  115 +
  116 + .time{
  117 + text-align: right;
  118 + color: #8C9198;
  119 + font-size: 22rpx;
  120 + }
  121 + }
  122 + }
  123 + .inputBox{
  124 + display: flex;
  125 + background-color: #fff;
  126 + padding: 16rpx 32rpx;
  127 + position: fixed;
  128 + bottom: 0;
  129 + .input{
  130 + width:506rpx;
  131 + height:68rpx;
  132 + background:rgba(238,238,238,1);
  133 + opacity:1;
  134 + border-radius:8rpx;
  135 + }
  136 + .btn{
  137 + width:150rpx;
  138 + height:68rpx;
  139 + background:rgba(129,195,191,1);
  140 + opacity:1;
  141 + border-radius:8rpx;
  142 + color: #fff;
  143 + text-align: center;
  144 + line-height: 68rpx;
  145 + font-size: 24rpx;
  146 + margin-left: 30rpx;
  147 + }
  148 + }
  149 +}
  150 +</style>
  1 +<template>
  2 + <view class="content">
  3 + <view class="item" v-for="(item,index) in mingxilist" :key="index">
  4 + <view class="left">
  5 + <view class="title">xx收益</view>
  6 + <view class="time">2020-2-19</view>
  7 + </view>
  8 + <view class="right">¥800.00</view>
  9 + </view>
  10 + <!-- <view class="item">
  11 + <view class="left">
  12 + <view class="title">提现</view>
  13 + <view class="time">2020-2-19</view>
  14 + </view>
  15 + <view class="right" style="color:#81C3BF">-¥800.00</view>
  16 + </view> -->
  17 + <view class="nodata" v-if="mingxilist.length==0">暂无数据</view>
  18 +
  19 + </view>
  20 +</template>
  21 +
  22 +<script>
  23 +import app from "../../App.vue";
  24 +export default {
  25 + data(){
  26 + return{
  27 + page:1,
  28 + size:10,
  29 + mingxilist:[]
  30 + }
  31 + },
  32 + methods:{
  33 + getyuE(){
  34 + var that = this
  35 + var url = "money/listMoneyLog"
  36 + var token = uni.getStorageSync('token')
  37 + var params = {
  38 + token:token,
  39 + page:that.page,
  40 + size:that.size
  41 + }
  42 + app.post(url,params,"get").then((res)=>{
  43 + console.log(res)
  44 + that.mingxilist=res
  45 + }).catch((err)=>{
  46 + console.log(err)
  47 + })
  48 + }
  49 + },
  50 + onLoad(){
  51 + this.getyuE()
  52 + }
  53 +}
  54 +</script>
  55 +
  56 +<style lang="less">
  57 +.content{
  58 + .nodata{
  59 + text-align: center;
  60 + font-size: 28rpx;
  61 + }
  62 + .item{
  63 + width: 686rpx;
  64 + margin: 0 auto;
  65 + display: flex;
  66 + justify-content: space-between;
  67 + align-items: center;
  68 + padding: 24rpx 0;
  69 + border-bottom: 1rpx solid rgba(238,238,238,1);
  70 + .left{
  71 + .title{
  72 + font-size: 28rpx;
  73 + }
  74 + .time{
  75 + font-size: 24rpx;
  76 + color:rgba(140,145,152,1);
  77 + }
  78 + }
  79 + .right{
  80 + font-size: 28rpx;
  81 + color:rgba(239,76,70,1);
  82 + }
  83 + }
  84 +}
  85 +</style>
  1 +<template>
  2 + <view class="content">
  3 + <view class="item" @click="toschoolmate" v-for="(item,index) in likepeoplelist" :key="index" :data-id="item.user_id">
  4 + <image class="photo" src="../../static/logo_img@2x.png"></image>
  5 + <view class="cont">
  6 + <view class="title">{{}}</view>
  7 + <view class="academy">
  8 + <image class="icon" src="../../static/xuexiao_icon@2x2.png"></image>河北工业大学 软件学院 软件工程
  9 + </view>
  10 + <view class="fen">裸分</view>
  11 + </view>
  12 + <view class="right">
  13 + <image src="../../static/yiguanzhu_img@2x.png"></image>
  14 + <view class="text">已关注</view>
  15 + </view>
  16 + </view>
  17 + <view class="nodata" v-if="likepeoplelist.length==0">暂无数据</view>
  18 +
  19 +
  20 +
  21 + </view>
  22 +</template>
  23 +
  24 +<script>
  25 +import app from "../../App.vue";
  26 +export default {
  27 +data(){
  28 + return{
  29 + page:1,
  30 + size:10,
  31 + likepeoplelist:[],
  32 +
  33 + }
  34 +},
  35 +methods:{
  36 + getlikepeople(){
  37 + var that = this
  38 + var url = 'student/getMyLikeStudent'
  39 + var token = uni.getStorageSync('token')
  40 + var params = {
  41 + token:token,
  42 + page:that.page,
  43 + size:that.size
  44 + }
  45 + app.post(url,params,"get").then((res)=>{
  46 + console.log(res)
  47 + that.likepeoplelist=res
  48 + }).catch((err)=>{
  49 + console.log(err)
  50 + })
  51 + },
  52 + toschoolmate(e){
  53 + var id = e.currentTarget.dataset.id
  54 + console.log(id)
  55 + uni.navigateTo({
  56 + url:"../school/schoolmateMsg?user_id="+id
  57 + })
  58 + }
  59 +},
  60 +onLoad(){
  61 + this.getlikepeople()
  62 +}
  63 +}
  64 +</script>
  65 +
  66 +<style lang="less">
  67 +.content{
  68 + background:rgba(249,249,249,1);
  69 + height: 100vh;
  70 + padding: 24rpx 0;
  71 + .nodata{
  72 + font-size: 28rpx;
  73 + text-align: center;
  74 + padding: 20rpx 0;
  75 + }
  76 + .item{
  77 + width:686rpx;
  78 + height:172rpx;
  79 + background:rgba(255,255,255,1);
  80 + opacity:1;
  81 + border-radius:8px;
  82 + margin: 0 auto;
  83 + background-color: #fff;
  84 + display: flex;
  85 + padding: 24rpx 32rpx;
  86 + box-sizing: border-box;
  87 + position: relative;
  88 + margin-bottom: 24rpx;
  89 + .photo{
  90 + width: 112rpx;
  91 + height: 112rpx;
  92 + margin-right: 26rpx;
  93 + margin-top: 6rpx;
  94 + }
  95 + .cont{
  96 + .title{
  97 + color:rgba(61,68,77,1);
  98 + font-size: 28rpx;
  99 + }
  100 + .academy{
  101 + color:rgba(61,68,77,1);
  102 + font-size: 22rpx;
  103 + margin-top: 4rpx;
  104 + display: flex;
  105 + align-items: center;
  106 + // line-height: 24rpx;
  107 + .icon{
  108 + width: 24rpx;
  109 + height: 24rpx;
  110 + margin-right: 6rpx;
  111 + }
  112 + }
  113 + .fen{
  114 + font-size: 22rpx;
  115 + color:rgba(140,145,152,1);
  116 + margin-top: 10rpx;
  117 + }
  118 + }
  119 + .right{
  120 + width: 132rpx;
  121 + height: 54rpx;
  122 + position: absolute;
  123 + right: 0;
  124 + top: 16rpx;
  125 + image{
  126 + width: 132rpx;
  127 + height: 54rpx;
  128 + }
  129 + .text{
  130 + color: #fff;
  131 + font-size: 24rpx;
  132 + width: 80rpx;
  133 + text-align: center;
  134 + position: absolute;
  135 + top: 50%;
  136 + left: 50%;
  137 + transform: translate(-50%,-50%);
  138 + }
  139 + }
  140 + }
  141 +}
  142 +</style>
  1 +<template>
  2 + <view class="content">
  3 + <view class="card">
  4 + <view class="item">
  5 + <view class="name">姓名</view>
  6 + <!-- <view class="cont">爱学习的王笑笑</view> -->
  7 + <input type="text" v-model="username" class="cont" :placeholder="userinfolist.nickname=='undefide' ? '' : userinfolist.nickname" placeholder-style="text-align: right" style="text-align: right">
  8 + </view>
  9 + <view class="item">
  10 + <view class="name">头像</view>
  11 + <image class="photo" @click="upload" :src="isUpload ? image : userinfolist.head_image"></image>
  12 + </view>
  13 + <view class="item">
  14 + <view class="name">高中</view>
  15 + <view class="cont">青岛市 青岛第一中学
  16 + <image class="icon" src="../../static/dizhi_btn@2x.png"></image>
  17 + </view>
  18 + </view>
  19 + <view class="item" style="border-bottom:none">
  20 + <view class="name">入学年份</view>
  21 + <view class="cont">2020年
  22 + <image class="icon" src="../../static/dizhi_btn@2x.png"></image>
  23 + </view>
  24 + </view>
  25 + </view>
  26 + <view class="btn" @click="update">保存</view>
  27 + </view>
  28 +</template>
  29 +
  30 +<script>
  31 +import app from "../../App.vue";
  32 +export default {
  33 + data(){
  34 + return{
  35 + username:'',
  36 + image:'',
  37 + image2:'',
  38 + isUpload:false,
  39 + userinfolist:{}
  40 + }
  41 + },
  42 + methods:{
  43 + upload(){
  44 + var that = this;
  45 + uni.chooseImage({
  46 + count: 1,
  47 + sizeType: ['original', 'compressed'], //可以指定是原图还是压缩图,默认二者都有
  48 + sourceType: ['album'], //从相册选择
  49 + success: function (res) {
  50 + const tempFilePaths = res.tempFilePaths;
  51 + that.image = tempFilePaths[0];
  52 + that.image2 = tempFilePaths[0];
  53 + app.upload('image',res.tempFilePaths[0],"post").then((res)=>{
  54 + // let newimage=that.image
  55 + that.image=app.globalData.imageBaseUrl+res.url
  56 + that.image2 = res.url
  57 + console.log(res)
  58 + console.log(that.image)
  59 + console.log(res.url)
  60 + // newimage.push(res.url)
  61 + that.isUpload=true
  62 + }).catch((err)=>{
  63 + console.log(err)
  64 + })
  65 + // console.log("tempFilePaths[0]",tempFilePaths[0]) //能够打印出选中的图片
  66 + // console.log(res)
  67 + // that.head_image=tempFilePaths[0]
  68 + // that.iconcheck = 1;//点击后图片更改状态由0变成1
  69 + },
  70 + error : function(e){
  71 + console.log(e);
  72 + }
  73 + });
  74 + },
  75 + getuserinfo(){
  76 + var that = this
  77 + var url = "student/getMyInfo"
  78 + var token = uni.getStorageSync('token')
  79 + var params = {
  80 + token:token
  81 + }
  82 + app.post(url,params,"get").then((res)=>{
  83 + console.log(res)
  84 + that.userinfolist=res
  85 + }).catch((err)=>{
  86 + console.log(err)
  87 + })
  88 + },
  89 + update(){
  90 + var that = this
  91 + var url = "student/updateStudentInfo"
  92 + var token = uni.getStorageSync('token')
  93 + var params= {
  94 + token:token,
  95 + nickname:that.username,
  96 + head_image:that.image2=='' ? that.userinfolist.head_image : that.image2
  97 + }
  98 + app.post(url,params,"post").then((res)=>{
  99 + console.log(res)
  100 +
  101 +
  102 + uni.showToast({
  103 + title:'个人信息保存成功',
  104 + icon:'none'
  105 + })
  106 + setTimeout(() => {
  107 + uni.navigateBack()
  108 + },1500);
  109 +
  110 + }).catch((err)=>{
  111 + console.log(err)
  112 + if(err.code==0){
  113 + uni.showToast({
  114 + title:err.msg,
  115 + icon:'none'
  116 + })
  117 + }
  118 + })
  119 +
  120 + }
  121 + },
  122 + onLoad(){
  123 + this.getuserinfo()
  124 + }
  125 +
  126 +}
  127 +</script>
  128 +
  129 +<style lang="less">
  130 +.content{
  131 + background-color: rgba(249,249,249,1);
  132 + padding: 32rpx 0;
  133 + height: 100vh;
  134 + .card{
  135 + width:686rpx;
  136 + // height:428rpx;
  137 + background:rgba(255,255,255,1);
  138 + opacity:1;
  139 + border-radius:20rpx;
  140 + margin: 0 auto;
  141 +
  142 + .item{
  143 + width: 622rpx;
  144 + display: flex;
  145 + justify-content: space-between;
  146 + align-items: center;
  147 + padding: 32rpx 0;
  148 + box-sizing: border-box;
  149 + font-size: 28rpx;
  150 + margin: 0 auto;
  151 + border-bottom: 1rpx solid rgba(238,238,238,1);
  152 + .photo{
  153 + width: 64rpx;
  154 + height: 64rpx;
  155 + border-radius: 50%;
  156 + }
  157 + .icon{
  158 + width: 11rpx;
  159 + height: 22rpx;
  160 + margin-left: 10rpx;
  161 + }
  162 + }
  163 + }
  164 + .btn{
  165 + width:684rpx;
  166 + height:80rpx;
  167 + background:rgba(45,85,117,1);
  168 + opacity:1;
  169 + border-radius:8rpx;
  170 + color: #fff;
  171 + line-height: 80rpx;
  172 + text-align: center;
  173 + margin: 0 auto;
  174 + margin-top: 620rpx;
  175 + }
  176 +}
  177 +</style>
  1 +<template>
  2 + <view class="content">
  3 + <image class="bg" src="../../static/bg_img2.png"></image>
  4 + <image class="photo" :src="token=='' ? '../../static/touxiang_img@2x.png' :head_image"></image>
  5 + <view class="title">{{userinfolist.nickname}}</view>
  6 + <image class="banner" src="../../static/banner_img@2x.png" @click="toBuyCard"></image>
  7 + <view class="item" @click="togeren">
  8 + <view class="name">
  9 + <image class="icon" src="../../static/8_icon@2x.png"></image>个人信息
  10 + </view>
  11 + <image class="right" src="../../static/dizhi_btn@2x.png"></image>
  12 + </view>
  13 +
  14 + <view class="item" @click="tocellect">
  15 + <view class="name">
  16 + <image class="icon" src="../../static/7_icon@2x.png"></image>我的文章
  17 + </view>
  18 + <image class="right" src="../../static/dizhi_btn@2x.png"></image>
  19 + </view>
  20 +
  21 + <view class="item" @click="tofollew">
  22 + <view class="name">
  23 + <image class="icon" src="../../static/6_icon@2x.png"></image>关注的人
  24 + </view>
  25 + <image class="right" src="../../static/dizhi_btn@2x.png"></image>
  26 + </view>
  27 +
  28 + <view class="item" @click="tocustom">
  29 + <view class="name">
  30 + <image class="icon" src="../../static/5_icon@2x.png"></image>消费记录
  31 + </view>
  32 + <image class="right" src="../../static/dizhi_btn@2x.png"></image>
  33 + </view>
  34 +
  35 + <view class="item" @click="tocomment">
  36 + <view class="name">
  37 + <image class="icon" src="../../static/4_icon@2x.png"></image>我的留言
  38 + </view>
  39 + <image class="right" src="../../static/dizhi_btn@2x.png"></image>
  40 + </view>
  41 + <!-- <tab></tab> -->
  42 + <!-- <tab :current="currentTabIndex" @getData="tabClick"></tab> -->
  43 + <view class="teacherfooter">
  44 +
  45 + <view class="teacherfootitem" v-if="type==1">
  46 + <view class="teacherfootitemtop" @click="footerselChange" :data-id="1" :data-url="'/pages/school/school?type='+1">
  47 + <image :src="footersel==1?'/static/xuexiao_icon@2x.png':'/static/xuexiao_icon@2x3.png'"></image>
  48 + </view>
  49 + <view class="teacherfootname" :class="footersel==1?'selactive':''">学校</view>
  50 + </view>
  51 + <view class="teacherfootitem" @click="footerselChange" :data-id="2" :data-url="'/pages/schoolmate/schoolmate?type='+1">
  52 + <view class="teacherfootitemtop">
  53 + <image :src="footersel==2?'/static/zhaoxiaoyou_icon@2x2.png':'/static/zhaoxiaoyou_icon@2x.png'"></image>
  54 + </view>
  55 + <view class="teacherfootname" :class="footersel==2?'selactive':''">找校友</view>
  56 + </view>
  57 + <view class="teacherfootitem" @click="footerselChange" :data-id="3" :data-url="'/pages/homePage/homePage?type='+1">
  58 + <view class="teacherfootitemtop">
  59 + <image :src="footersel==3?'/static/wodezhuye_icon@2x2.png':'/static/wodezhuye_icon@2x.png'"></image>
  60 + </view>
  61 + <view class="teacherfootname" :class="footersel==3?'selactive':''">我的主页</view>
  62 + </view>
  63 + </view>
  64 + <view class="collegefooter" v-if="type == 2">
  65 + <view class="teacherfootitem" @click="footerselChange" :data-id="2" :data-url="'/pages/schoolmate/schoolmate?type='+2">
  66 + <view class="teacherfootitemtop">
  67 + <image :src="footersel==2?'/static/zhaoxiaoyou_icon@2x2.png':'/static/zhaoxiaoyou_icon@2x.png'"></image>
  68 + </view>
  69 + <view class="teacherfootname" :class="footersel==2?'selactive':''">找校友</view>
  70 + </view>
  71 + <view class="teacherfootitem" @click="footerselChange" :data-id="3" :data-url="'/pages/homePage/collegeHome?type='+2">
  72 + <view class="teacherfootitemtop">
  73 + <image :src="footersel==3?'/static/wodezhuye_icon@2x2.png':'/static/wodezhuye_icon@2x.png'"></image>
  74 + </view>
  75 + <view class="teacherfootname" :class="footersel==3?'selactive':''">我的主页</view>
  76 + </view>
  77 + </view>
  78 +
  79 +
  80 + </view>
  81 +</template>
  82 +
  83 +<script>
  84 + import app from "../../App.vue";
  85 + export default {
  86 +
  87 + data() {
  88 + return {
  89 + currentTabIndex: 2,
  90 + footersel:3,
  91 + type:"",
  92 + userinfolist:{},
  93 + token:'',
  94 + head_image:''
  95 + }
  96 + },
  97 + methods: {
  98 + toBuyCard() {
  99 + if(uni.getStorageSync('token')==''){
  100 + uni.navigateTo({
  101 + url:'../register/register?istoken='+1
  102 + })
  103 + }else{
  104 + wx.navigateTo({
  105 + url:'./buyCard'
  106 + })
  107 + }
  108 + },
  109 + // 底部导航跳转
  110 + footerselChange(e){
  111 + let url=e.currentTarget.dataset.url;
  112 + console.log(url)
  113 + uni.redirectTo({
  114 +
  115 + url:url
  116 + })
  117 + },
  118 + getuserinfo(){
  119 + var that = this
  120 + var url = "student/getMyInfo"
  121 + var token = uni.getStorageSync('token')
  122 + var params = {
  123 + token:token
  124 + }
  125 + app.post(url,params,"get").then((res)=>{
  126 + console.log(res)
  127 + that.userinfolist=res;
  128 + console.log(res.head_image)
  129 + that.head_image=res.head_image
  130 + }).catch((err)=>{
  131 + console.log(err)
  132 + })
  133 + },
  134 + // tocomment(){
  135 + // uni.navigateTo({
  136 + // url:'./mycomment?user_id='+this.userinfolist.user_id
  137 + // })
  138 + // },
  139 + togeren(){
  140 + if(uni.getStorageSync('token')==''){
  141 + uni.showToast({
  142 + title:"请登陆后操作",
  143 + icon:"none"
  144 + })
  145 + setTimeout(() => {
  146 + uni.navigateTo({
  147 + url:'../register/register?istoken='+1
  148 + })
  149 + },1500);
  150 + }else{
  151 + wx.navigateTo({
  152 + url:'./gerencenter'
  153 + })
  154 + }
  155 + },
  156 + tocellect(){
  157 + if(uni.getStorageSync('token')==''){
  158 + uni.showToast({
  159 + title:"请登陆后操作",
  160 + icon:"none"
  161 + })
  162 + setTimeout(() => {
  163 + uni.navigateTo({
  164 + url:'../register/register?istoken='+1
  165 + })
  166 + },1500);
  167 + }else{
  168 + wx.navigateTo({
  169 + url:'./cellect'
  170 + })
  171 + }
  172 + },
  173 + tofollew(){
  174 + if(uni.getStorageSync('token')==''){
  175 + uni.showToast({
  176 + title:"请登陆后操作",
  177 + icon:"none"
  178 + })
  179 + setTimeout(() => {
  180 + uni.navigateTo({
  181 + url:'../register/register?istoken='+1
  182 + })
  183 + },1500);
  184 + }else{
  185 + wx.navigateTo({
  186 + url:'./followPeople'
  187 + })
  188 + }
  189 + },
  190 + tocustom(){
  191 + if(uni.getStorageSync('token')==''){
  192 + uni.showToast({
  193 + title:"请登陆后操作",
  194 + icon:"none"
  195 + })
  196 + setTimeout(() => {
  197 + uni.navigateTo({
  198 + url:'../register/register?istoken='+1
  199 + })
  200 + },1500);
  201 + }else{
  202 + wx.navigateTo({
  203 + url:'./consumePage'
  204 + })
  205 + }
  206 + },
  207 + tocomment(){
  208 + if(uni.getStorageSync('token')==''){
  209 + uni.showToast({
  210 + title:"请登陆后操作",
  211 + icon:"none"
  212 + })
  213 + setTimeout(() => {
  214 + uni.navigateTo({
  215 + url:'../register/register?istoken='+1
  216 + })
  217 + },1500);
  218 + }else{
  219 + uni.navigateTo({
  220 + url:'./mycomment?user_id='+this.userinfolist.user_id
  221 + })
  222 + }
  223 + }
  224 + },
  225 + onLoad(options){
  226 + this.token=uni.getStorageSync('token')
  227 + console.log(options.type)
  228 + var type=options.type
  229 + this.type=type
  230 + this.getuserinfo()
  231 + },
  232 + }
  233 +</script>
  234 +
  235 +<style lang="less">
  236 +
  237 + .content {
  238 + text-align: center;
  239 + color: rgba(6, 18, 30, 1);
  240 + padding-bottom: 120rpx;
  241 + .bg {
  242 + width: 750rpx;
  243 + height: 154rpx;
  244 + }
  245 +
  246 + .photo {
  247 + width: 136rpx;
  248 + height: 136rpx;
  249 + position: absolute;
  250 + top: 52rpx;
  251 + left: 50%;
  252 + transform: translate(-50%);
  253 + }
  254 +
  255 + .title {
  256 + margin-top: 66rpx;
  257 + }
  258 +
  259 + .banner {
  260 + margin-top: 78rpx;
  261 + width: 686rpx;
  262 + height: 216rpx;
  263 + margin-bottom: 30rpx;
  264 + }
  265 +
  266 + .item {
  267 + display: flex;
  268 + align-items: center;
  269 + justify-content: space-between;
  270 + width: 686rpx;
  271 + margin: 0 auto;
  272 + padding: 32rpx 0;
  273 + border-bottom: 1rpx solid rgba(238, 238, 238, 1);
  274 +
  275 + .icon {
  276 + width: 36rpx;
  277 + height: 36rpx;
  278 + margin-right: 12rpx;
  279 + }
  280 +
  281 + .name {
  282 + font-size: 28rpx;
  283 + display: flex;
  284 + align-items: center;
  285 + }
  286 +
  287 + .right {
  288 + width: 10rpx;
  289 + height: 19rpx;
  290 + }
  291 + }
  292 + }
  293 +</style>
  1 +<template>
  2 + <view class="content">
  3 + <view class="item" @click="tocommentlist(item)" v-for="(item,index) in commentlist" :key="index">
  4 + <view class="toprow">
  5 + <image class="photo" src="../../static/logo_img@2x.png"></image>
  6 + <view class="msg">
  7 + <view class="name">{{item.nickname}}</view>
  8 + <view class="time">{{item.createtime}}</view>
  9 + </view>
  10 + <view class="right" v-if="item.readtime==null">未读</view>
  11 + <view class="right" style="color:#BDC4CE" v-else>已读</view>
  12 + </view>
  13 + <view class="bottomrow">
  14 + {{item.des_content}}
  15 + </view>
  16 + </view>
  17 + <view class="nodata" v-if="commentlist.length==0">暂无数据</view>
  18 +
  19 + </view>
  20 +</template>
  21 +
  22 +<script>
  23 +import app from "../../App.vue";
  24 +export default {
  25 + data(){
  26 + return{
  27 + page:1,
  28 + size:10,
  29 + commentlist:[],
  30 + user_id:''
  31 + }
  32 + },
  33 + methods:{
  34 + getcommentlist(){
  35 + var that = this
  36 + var url = "mes/getMyMes"
  37 + var token = uni.getStorageSync('token')
  38 + var params = {
  39 + token:token,
  40 + page:that.page,
  41 + size:that.size,
  42 +
  43 + }
  44 + app.post(url,params,"get").then((res)=>{
  45 + console.log(res)
  46 + that.commentlist=res
  47 + }).catch((err)=>{
  48 + console.log(err)
  49 + })
  50 + },
  51 + tocommentlist(item){
  52 + uni.navigateTo({
  53 + url:'./commentContent?userb_id='+item.userb_id+"&nickname="+item.nickname+"&head_image="+item.head_image+"&user_id="+this.user_id
  54 + })
  55 + var that = this
  56 + var url = "mes/isReadMes"
  57 + var token = uni.getStorageSync('token')
  58 + var params = {
  59 + token:token,
  60 + usera_id:item.userb_id
  61 + }
  62 + app.post(url,params,"post").then((res)=>{
  63 + console.log(res)
  64 + }).catch((err)=>{
  65 + console.log(err)
  66 + })
  67 + }
  68 + },
  69 + onLoad(options){
  70 + this.user_id=options.user_id
  71 + this.getcommentlist()
  72 + }
  73 +
  74 +}
  75 +</script>
  76 +
  77 +<style lang="less">
  78 +.content{
  79 + background:rgba(249,249,249,1);
  80 + padding: 28rpx 0;
  81 + .nodata{
  82 + font-size: 28rpx;
  83 + text-align: center;
  84 + padding: 20rpx 0;
  85 + }
  86 + .item{
  87 + width: 686rpx;
  88 + margin: 0 auto;
  89 + background-color: #fff;
  90 + padding: 32rpx;
  91 + box-sizing: border-box;
  92 + margin-bottom: 28rpx;
  93 + }
  94 + .toprow{
  95 + display: flex;
  96 + // justify-content: space-between;
  97 + .photo{
  98 + width: 68rpx;
  99 + height: 68rpx;
  100 + }
  101 + .msg{
  102 + // width: 200rpx;
  103 + margin-left: 20rpx;
  104 + .name{
  105 + font-size: 24rpx;
  106 + }
  107 + .time{
  108 + color:rgba(140,145,152,1);
  109 + font-size:22rpx;
  110 + }
  111 + }
  112 + .right{
  113 + color:rgba(235,128,121,1);
  114 + font-size: 24rpx;
  115 + margin-left: 324rpx;
  116 + // float: right;
  117 + width: 60rpx;
  118 + }
  119 + .readed{
  120 + color:rgba(189,196,206,1);
  121 + font-size: 24rpx;
  122 + margin-left: 364rpx;
  123 + }
  124 + }
  125 + .bottomrow{
  126 + font-size:24rpx;
  127 + margin-top: 24rpx;
  128 + }
  129 +}
  130 +</style>
  1 +<template>
  2 + <view class="content">
  3 + <navigator class="mingxi" hover-class="none" url="./yuE">余额明细</navigator>
  4 + <view class="title">钱包余额(元)</view>
  5 + <view class="money">{{monery}}</view>
  6 + <view class="btn" @click="totixian">立即提现</view>
  7 + </view>
  8 +</template>
  9 +
  10 +<script>
  11 +import app from "../../App.vue";
  12 +export default {
  13 + data(){
  14 + return{
  15 + monery:''
  16 + }
  17 + },
  18 + methods:{
  19 + getyuE(){
  20 + var that = this
  21 + var url = "money/getStudentMoney"
  22 + var token = uni.getStorageSync('token')
  23 + var params = {
  24 + token:token
  25 + }
  26 + app.post(url,params,"get").then((res)=>{
  27 + console.log(res)
  28 + that.monery=res
  29 + }).catch((err)=>{
  30 + console.log(err)
  31 + })
  32 + },
  33 + totixian(){
  34 + uni.navigateTo({
  35 + url:'./tixianPage?money='+this.monery
  36 + })
  37 + }
  38 + },
  39 + onLoad(){
  40 + this.getyuE()
  41 + }
  42 +}
  43 +</script>
  44 +
  45 +<style lang="less">
  46 +.content{
  47 + padding: 24rpx 32rpx;
  48 + .mingxi{
  49 + text-align: right;
  50 + text-decoration:underline;
  51 + font-size:24rpx;
  52 + }
  53 + .title{
  54 + text-align: center;
  55 + margin-top: 186rpx;
  56 + }
  57 + .money{
  58 + text-align: center;
  59 + font-size:88rpx;
  60 + margin-top: 12rpx;
  61 + }
  62 + .btn{
  63 + width:592rpx;
  64 + height:80rpx;
  65 + background:rgba(45,85,117,1);
  66 + opacity:1;
  67 + border-radius:8rpx;
  68 + color: #fff;
  69 + font-size: 28rpx;
  70 + text-align: center;
  71 + line-height: 80rpx;
  72 + margin: 0 auto;
  73 + margin-top: 376rpx;
  74 + }
  75 +}
  76 +</style>
  1 +<template>
  2 + <view class="content">
  3 + <view class="box">
  4 + <view class="item">
  5 + <input type="text" v-model="title" placeholder="请添加文章标题" placeholder-style="font-size:32rpx;color:rgba(189,196,206,1);" style="">
  6 + </view>
  7 + <view class="item">
  8 + <view class="left">文章类型</view>
  9 + <view class="right" @click="seltype">
  10 + <!-- <input type="text" class="input" placeholder="请选择文章类型" placeholder-style="color:rgba(189,196,206,1);font-size:28rpx"> -->
  11 + <picker mode="selector" :value="type" @change="bindTypeChange" :range="typearray" range-key='name' :data-id="typearray[type].id">
  12 + <view class="text" style="color:rgba(189,196,206,1);font-size:28rpx">{{istypeshow? typearray[type].name : '请选择文章类型'}}</view>
  13 + </picker>
  14 + <image class="icon" src="../../static/dizhi_btn@2x2.png"></image>
  15 + </view>
  16 + </view>
  17 + <view class="item">
  18 + <view class="left">开放范围</view>
  19 + <view class="right">
  20 + <view class="selected" @click="selectrange" data-id='1'>
  21 + <image class="icon" :src="show_type==1 ? '../../static/xuanzhong_img@2x.png' : '../../static/weixuanzhong_img@2x.png'"></image>
  22 + 仅校友
  23 + </view>
  24 + <view class="selected" @click="selectrange" data-id='2'>
  25 + <image class="icon" :src="show_type==2 ? '../../static/xuanzhong_img@2x.png' : '../../static/weixuanzhong_img@2x.png'"></image>
  26 + 全部
  27 + </view>
  28 + </view>
  29 + </view>
  30 + <view class="item2">
  31 + <textarea v-model="articlecontent" name="" id="" cols="30" rows="10" class="textarea" placeholder="请输入文章内容" placeholder-style="color:rgba(189,196,206,1);font-size:28rpx"></textarea>
  32 + <view class="tips">可输入1000字</view>
  33 + </view>
  34 + <view class="picBox">
  35 + <!-- <view class="boxitem">
  36 + <image class="pic" src="../../static/bg_img@2x.png"></image>
  37 + <image class="icon" src="../../static/shanchu_icon@2x.png"></image>
  38 + </view>
  39 + <view class="boxitem">
  40 + <image class="pic" src="../../static/bg_img@2x.png"></image>
  41 + <image class="icon" src="../../static/shanchu_icon@2x.png"></image>
  42 + </view>
  43 + <view class="boxitem">
  44 + <image class="pic" src="../../static/bg_img@2x.png"></image>
  45 + <image class="icon" src="../../static/shanchu_icon@2x.png"></image>
  46 + </view>
  47 + <view class="boxitem">
  48 + <image class="pic" src="../../static/bg_img@2x.png"></image>
  49 + <image class="icon" src="../../static/shanchu_icon@2x.png"></image>
  50 + </view> -->
  51 +
  52 + <view class="boxitem">
  53 + <view class="imagebox" v-for="(item,index) in image" :key="index">
  54 + <image :src="item" style="width:128rpx;height:128rpx;margin-right: 24rpx;margin-bottom: 24rpx;"></image>
  55 + <image class="icon" src="../../static/shanchu_icon@2x.png" @click="delimage(index)"></image>
  56 + </view>
  57 + <image class="pic" src="../../static/shangchuan_img@2x.png" @click="upload"></image>
  58 + </view>
  59 +
  60 + </view>
  61 + </view>
  62 + <view class="btn" @click="pubarticle">确认发布</view>
  63 + </view>
  64 +</template>
  65 +
  66 +<script>
  67 +import app from "../../App.vue";
  68 +export default {
  69 + data(){
  70 + return{
  71 + title:'',
  72 + // range:'1',
  73 + type:0,
  74 + istypeshow:false,
  75 + typearray:["经验","感受"],
  76 + articlecontent:'',
  77 + image:[],
  78 + image2:[],
  79 + isUpload:false,
  80 + article_type_id:'',
  81 + show_type:1,
  82 +
  83 + }
  84 + },
  85 + methods:{
  86 + selectrange(e){
  87 + this.show_type=e.currentTarget.dataset.id
  88 +
  89 + },
  90 + seltype(){
  91 + this.istypeshow=true
  92 + },
  93 + bindTypeChange(e){
  94 + console.log(e.target)
  95 + this.type = e.target.value
  96 + console.log(e.currentTarget)
  97 + this.article_type_id=e.currentTarget.dataset.id
  98 + },
  99 + upload(){
  100 + var that = this;
  101 + uni.chooseImage({
  102 + count: 1,
  103 + sizeType: ['original', 'compressed'], //可以指定是原图还是压缩图,默认二者都有
  104 + sourceType: ['album'], //从相册选择
  105 + success: function (res) {
  106 + const tempFilePaths = res.tempFilePaths;
  107 + // that.image = that.image.push(tempFilePaths[0]) ;
  108 + app.upload('image',res.tempFilePaths[0],"post").then((res)=>{
  109 + // let newimage=that.image
  110 + var url= app.globalData.imageBaseUrl+res.url
  111 + // that.image=app.globalData.imageBaseUrl+res.url
  112 + console.log(res)
  113 + console.log(res.url)
  114 + console.log(that.image)
  115 +
  116 + that.image.push(url)
  117 + that.image2.push(res.url)
  118 + console.log(that.image)
  119 +
  120 + // that.image=that.image
  121 +
  122 + that.isUpload=true
  123 + }).catch((err)=>{
  124 + console.log(err)
  125 + })
  126 + // console.log("tempFilePaths[0]",tempFilePaths[0]) //能够打印出选中的图片
  127 + // console.log(res)
  128 + // that.head_image=tempFilePaths[0]
  129 + // that.iconcheck = 1;//点击后图片更改状态由0变成1
  130 + },
  131 + error : function(e){
  132 + console.log(e);
  133 + }
  134 + });
  135 + },
  136 + pubarticle(){
  137 + var that= this
  138 + if(that.title==''){
  139 + uni.showToast({
  140 + title:"请输入文章标题",
  141 + icon:"none"
  142 + })
  143 + return false
  144 + }
  145 + if(that.type==''){
  146 + uni.showToast({
  147 + title:"请选择文章类型",
  148 + icon:"none"
  149 + })
  150 + return false
  151 + }
  152 + if(that.articlecontent==''){
  153 + uni.showToast({
  154 + title:"请输入文章内容",
  155 + icon:"none"
  156 + })
  157 + return false
  158 + }else if (that.articlecontent.length>1000){
  159 + uni.showToast({
  160 + title:"已超过最大字数",
  161 + icon:"none"
  162 + })
  163 + }
  164 +
  165 + // if(that.image.length==0){
  166 + // uni.showToast({
  167 + // title:"请添加文章图片",
  168 + // icon:"none"
  169 + // })
  170 + // return false
  171 + // }
  172 + var url = "article/addArticle"
  173 + var token = uni.getStorageSync('token')
  174 + console.log(token)
  175 + var params={
  176 + token:token,
  177 + title:that.title,
  178 + article_type_id:that.article_type_id,
  179 + show_type:that.show_type,
  180 + des_content:that.articlecontent,
  181 + des_images:that.image2.join(",")
  182 + }
  183 + app.post(url,params,"post").then((res)=>{
  184 + console.log(res)
  185 + uni.showToast({
  186 + title:"文章已发布,审核中",
  187 + icon:"none"
  188 + })
  189 + setTimeout(() => {
  190 + uni.navigateBack()
  191 + },1500);
  192 +
  193 + // uni.navigateTo({
  194 + // url:"./homePage"
  195 + // })
  196 + }).catch((err)=>{
  197 + console.log(err)
  198 + })
  199 + },
  200 + getAllType(){
  201 + var that = this
  202 + var url = "article/getArticleType"
  203 + var params = {}
  204 + app.post(url,params,"get").then((res)=>{
  205 + console.log(res)
  206 + that.typearray=res
  207 + }).catch((err)=>{
  208 + console.log(err)
  209 + })
  210 + },
  211 + delimage(index){
  212 + this.image.splice(index,1)
  213 + }
  214 + },
  215 + onLoad(){
  216 + this.getAllType()
  217 + }
  218 +
  219 +}
  220 +</script>
  221 +
  222 +<style lang="less">
  223 +.content{
  224 + background-color: #F9F9F9;
  225 + padding: 32rpx;
  226 + .box{
  227 + background-color: #fff;
  228 + width:686rpx;
  229 + // height:976rpx;
  230 + background:rgba(255,255,255,1);
  231 + opacity:1;
  232 + border-radius:20rpx;
  233 + margin: 0 auto;
  234 + .item{
  235 + width:622rpx;
  236 + margin:0 auto;
  237 + padding: 32rpx 0;
  238 + border-bottom: 1rpx solid rgba(238,238,238,1);
  239 + display: flex;
  240 + justify-content: space-between;
  241 +
  242 + .left{
  243 + font-size: 28rpx;
  244 + }
  245 + .right{
  246 + display: flex;
  247 + align-items: center;
  248 + font-size: 28rpx;
  249 +
  250 + .input{
  251 + width: 200rpx;
  252 +
  253 + }
  254 + .icon{
  255 + width: 13rpx;
  256 + height: 25rpx;
  257 + margin-left: 8rpx;
  258 + }
  259 + .selected{
  260 + .icon{
  261 + width: 20rpx;
  262 + height: 20rpx;
  263 + margin-left: 40rpx;
  264 + margin-right: 10rpx;
  265 + }
  266 + }
  267 + }
  268 + }
  269 + .item2{
  270 + padding: 32rpx;
  271 + width: 686rpx;
  272 + .textarea{
  273 + width: 622rpx;
  274 + font-size: 28rpx;
  275 + }
  276 + .tips{
  277 + font-size: 24rpx;
  278 + text-align: right;
  279 + width: 622rpx;
  280 + }
  281 + }
  282 + .picBox{
  283 + padding: 32rpx;
  284 + width: 460rpx;
  285 + display: flex;
  286 + flex-wrap: wrap;
  287 + .boxitem{
  288 + width: 460rpx;
  289 +
  290 + // margin-right: 24rpx;
  291 + // margin-bottom: 24rpx;
  292 + display: flex;
  293 + flex-wrap: wrap;
  294 + justify-content: start;
  295 + .imagebox{
  296 + width: 128rpx;
  297 + height: 128rpx;
  298 + position: relative;
  299 + display: inline-block;
  300 + margin-right: 24rpx;margin-bottom: 24rpx;
  301 +
  302 + }
  303 + .pic{
  304 + width: 128rpx;
  305 + height: 128rpx;
  306 + margin-right: 24rpx;margin-bottom: 24rpx;
  307 + }
  308 + .icon{
  309 + width: 36rpx;
  310 + height: 36rpx;
  311 + position: absolute;
  312 + right: -18rpx;
  313 + top: -18rpx;
  314 +
  315 + }
  316 + }
  317 + }
  318 + }
  319 + .btn{
  320 + width:684rpx;
  321 + height:80rpx;
  322 + background:rgba(45,85,117,1);
  323 + opacity:1;
  324 + border-radius:8rpx;
  325 + color: #fff;
  326 + text-align: center;
  327 + line-height: 80rpx;
  328 + font-size: 28rpx;
  329 + margin-top: 54rpx;
  330 + }
  331 +}
  332 +</style>
  1 +<template>
  2 + <view class="content">
  3 + <image class="bg" src="../../static/bg_img@2x(2).png"></image>
  4 + <view class="card">
  5 + <view class="title">提现到微信余额(元)</view>
  6 + <!-- <view class="money">100.00</view> -->
  7 + <input type="text" v-model="money" class="money" placeholder="100.00" placeholder-style="padding-bottom: 10rpx;color:rgba(189,196,206,1);font-size: 80rpx;margin-top: 16rpx;border-bottom: 1rpx solid rgba(112,112,112,1);">
  8 + <view class="text">最多可提100.00元,<text>全部提现</text></view>
  9 + <view class="btn" @click="tixian">提现</view>
  10 + </view>
  11 + <view class="textBox">
  12 + YHA青年旅舍会员卡(一年)是国际青年旅舍联盟会员身份证明,全球通用,也是旅行者入住青年旅舍的凭证。拥有会员卡,可以享受国内外国际青年旅舍住宿价格的优惠,同时部分海外青年旅舍只允许会员入住。
  13 + 成为YHA青年旅舍会员的好处:
  14 + <view>1)入住青年旅舍享受房价上的优惠;</view>
  15 + <view>2)在世界各地享有食、住、行、游、购、娱等逾3,000项优惠,如:在全球多个国际机场和车船站,凭会员卡兑换外币可免收手续费;观光、租车、购物、参团、购买车船票等均可能有折扣,折扣率高达50%。单是在澳大利亚,优惠项目便接近800种;</view>
  16 + <view>3)以优惠价格参与多项由青年旅舍举办的各类文化、旅游等方面的交流活动;</view>
  17 + <view>4)优先参与青年旅舍组织的国际交流活动。</view>
  18 +
  19 + </view>
  20 + </view>
  21 +</template>
  22 +
  23 +<script>
  24 +import app from "../../App.vue";
  25 +export default {
  26 + data(){
  27 + return{
  28 + money:'',
  29 + yue:''
  30 + }
  31 + },
  32 + methods:{
  33 + tixian(){
  34 + var that = this
  35 + if(that.money==''){
  36 + uni.showToast({
  37 + title:"提现金额不能为空",
  38 + icon:"none"
  39 + })
  40 + return false
  41 + }
  42 + if(that.money>that.yue){
  43 + uni.showToast({
  44 + title:"提现金额不足",
  45 + icon:"none"
  46 + })
  47 + return false
  48 + }
  49 + var url = "money/gotMoney"
  50 + var token = uni.getStorageSync('token')
  51 + var params = {
  52 + token:token,
  53 + money:that.money
  54 + }
  55 + app.post(url,params,"post").then((res)=>{
  56 + console.log(res)
  57 + }).catch((err)=>{
  58 + console.log(err)
  59 + })
  60 + }
  61 + },
  62 + onLoad(options){
  63 + this.yue=options.money
  64 + }
  65 +
  66 +}
  67 +</script>
  68 +
  69 +<style lang="less">
  70 +.content{
  71 + background-color: #F9F9F9;
  72 + .bg{
  73 + width: 750rpx;
  74 + height: 292rpx;
  75 + }
  76 + .card{
  77 + width:686rpx;
  78 + height:514rpx;
  79 + background:rgba(255,255,255,1);
  80 + box-shadow:0rpx 4rpx 6rpx rgba(45,85,117,0.1);
  81 + opacity:1;
  82 + border-radius:20rpx;
  83 + position: absolute;
  84 + top: 26rpx;
  85 + left: 32rpx;
  86 + padding: 68rpx 46rpx 40rpx;
  87 + box-sizing: border-box;
  88 + color:rgba(6,18,30,1);
  89 + .title{
  90 + font-size: 28rpx;
  91 + }
  92 + .money{
  93 + color:rgba(189,196,206,1);
  94 + font-size: 80rpx;
  95 + margin-top: 16rpx;
  96 + border-bottom: 1rpx solid rgba(112,112,112,1);
  97 + height: 90rpx;
  98 + }
  99 + .text{
  100 + font-size:24rpx;
  101 + margin-top: 22rpx;
  102 + text{
  103 + color: #81C3BF;
  104 +
  105 + }
  106 + }
  107 + .btn{
  108 + width:596rpx;
  109 + height:76rpx;
  110 + background:rgba(45,85,117,1);
  111 + opacity:1;
  112 + border-radius:8rpx;
  113 + text-align: center;
  114 + line-height: 76rpx;
  115 + color: #fff;
  116 + font-size: 28rpx;
  117 + margin-top: 90rpx;
  118 + }
  119 + }
  120 + .textBox{
  121 + width:636rpx;
  122 + height:586rpx;
  123 + font-size:24rpx;
  124 + font-family:PingFang SC;
  125 + font-weight:400;
  126 + line-height:40rpx;
  127 + color:rgba(6,18,30,1);
  128 + opacity:1;
  129 + margin: 0 auto;
  130 + margin-top: 274rpx;
  131 + }
  132 +}
  133 +</style>
  1 +<template>
  2 + <view class="content">
  3 + <view class="item" v-for="(item,index) in mingxilist" :key="index">
  4 + <view class="left">
  5 + <view class="title">xx收益</view>
  6 + <view class="time">2020-2-19</view>
  7 + </view>
  8 + <view class="right">¥800.00</view>
  9 + </view>
  10 + <view class="nodata" v-if="mingxilist.length==0">暂无数据</view>
  11 + </view>
  12 +</template>
  13 +
  14 +<script>
  15 +import app from "../../App.vue";
  16 +export default {
  17 + data(){
  18 + return{
  19 + page:1,
  20 + size:10,
  21 + mingxilist:[]
  22 + }
  23 + },
  24 + methods:{
  25 + getyuE(){
  26 + var that = this
  27 + var url = "money/listMoneyLog"
  28 + var token = uni.getStorageSync('token')
  29 + var params = {
  30 + token:token,
  31 + page:that.page,
  32 + size:that.size
  33 + }
  34 + app.post(url,params,"get").then((res)=>{
  35 + console.log(res)
  36 + that.mingxilist=res
  37 + }).catch((err)=>{
  38 + console.log(err)
  39 + })
  40 + }
  41 + },
  42 + onLoad(){
  43 + this.getyuE()
  44 + }
  45 +}
  46 +</script>
  47 +
  48 +<style lang="less">
  49 +.content{
  50 + .nodata{
  51 + font-size: 28rpx;
  52 + text-align: center;
  53 + padding: 20rpx 0;
  54 + }
  55 + .item{
  56 + width: 686rpx;
  57 + margin: 0 auto;
  58 + display: flex;
  59 + justify-content: space-between;
  60 + align-items: center;
  61 + padding: 24rpx 0;
  62 + border-bottom: 1rpx solid rgba(238,238,238,1);
  63 + .left{
  64 + .title{
  65 + font-size: 28rpx;
  66 + }
  67 + .time{
  68 + font-size: 24rpx;
  69 + color:rgba(140,145,152,1);
  70 + }
  71 + }
  72 + .right{
  73 + font-size: 28rpx;
  74 + color:rgba(239,76,70,1);
  75 + }
  76 + }
  77 +}
  78 +</style>
  1 +<template>
  2 +
  3 +</template>
  4 +
  5 +<script>
  6 +export default {
  7 +
  8 +}
  9 +</script>
  10 +
  11 +<style>
  12 +
  13 +</style>
  1 +<template>
  2 + <view class="content">
  3 + <view class="selectCard">
  4 + <view class="item">
  5 + <view class="title">所在地区</view>
  6 + <view class="selectBtn" @click="seldiqu">{{provname}}-{{cityname}}<image class="icon" src="../../static/zhuandao_icon@2x.png"></image></view>
  7 + </view>
  8 +
  9 + <view class="item" style="border-bottom:none">
  10 + <view class="title">高中名称</view>
  11 + <input type="text" v-model="schoolname" class="inpt" placeholder="请输入高中名称" placeholder-style="color:rgba(189,196,206,1);font-size:28rpx;">
  12 + </view>
  13 + </view>
  14 + <view class="diquPopup" v-if="isDiquShow">
  15 +
  16 + <view class="cont">
  17 + <view class="colum" style="overflow: auto;height: 540rpx;">
  18 + <!-- <view class="title" @click="selectprovince" :data-id="''">全部省</view> -->
  19 + <view class="item" @click="selectprovince" v-for="(item,index) in provinceList" :key="index" :data-id="item.code" :data-prov="item.name">{{item.name}}</view>
  20 +
  21 + </view>
  22 + <view class="colum" style="overflow: auto;height: 540rpx;">
  23 + <view class="title" @click="selectcity" :data-id="''">全部市</view>
  24 + <view class="item" @click="selectcity" v-for="(item,index) in cityList" :key="index" :data-id="item.code" :data-city="item.name">{{item.name}}</view>
  25 +
  26 + </view>
  27 + <!-- <view class="colum" style="overflow: auto;height: 224rpx;">
  28 + <view class="title" @click="selectschool" :data-id="null">全部学校</view>
  29 + <view class="item" @click="selectschool" v-for="(item,index) in schoolList" :key="index" :data-id="item.id">{{item.name}}</view>
  30 +
  31 + </view> -->
  32 +
  33 + </view>
  34 + </view>
  35 + <view class="btn" @click="popupShow">提交</view>
  36 + <view class="popup" v-if="isPopupShow">
  37 + <view class="card">
  38 + <view class="title">提交成功</view>
  39 + <view class="tips">学校将在72小时内审核添加</view>
  40 + <view class="okBtn" @click="popupHide">确定</view>
  41 + </view>
  42 + </view>
  43 + </view>
  44 +
  45 +</template>
  46 +
  47 +<script>
  48 +import app from "../../App.vue";
  49 +export default {
  50 + data(){
  51 + return{
  52 + isPopupShow:false,
  53 + isDiquShow:false,
  54 + province_id:'',
  55 + city_id:'',
  56 + school_id:'',
  57 + cityList:[],
  58 + provinceList:[],
  59 + provname:'XX省',
  60 + cityname:'XX市',
  61 + schoolname:''
  62 +
  63 + }
  64 + },
  65 + methods:{
  66 + popupShow(){
  67 +
  68 + var that = this
  69 + var url = "school/addOneSchool"
  70 + var params = {
  71 + name:that.schoolname,
  72 + province_id:that.province_id,
  73 + city_id:that.city_id
  74 + }
  75 + app.post(url,params,"post").then((res)=>{
  76 + console.log(res)
  77 + this.isPopupShow=true
  78 + }).catch((err)=>{
  79 + console.log(err)
  80 + })
  81 + },
  82 + popupHide(){
  83 + this.isPopupShow=false
  84 + uni.navigateBack()
  85 + },
  86 + seldiqu(){
  87 + this.isDiquShow=true
  88 + },
  89 + //点击选中的省
  90 + selectprovince(e){
  91 + this.province_id=e.currentTarget.dataset.id
  92 + this.getAllCity()
  93 + this.provname=e.currentTarget.dataset.prov
  94 + },
  95 + //点击选中的市
  96 + selectcity(e){
  97 + this.city_id=e.currentTarget.dataset.id
  98 + // this.getAllSchool()
  99 + this.isDiquShow=false
  100 + this.cityname=e.currentTarget.dataset.city
  101 +
  102 +
  103 + },
  104 + //获取全部地区(省)
  105 + getAllProvince(){
  106 + var url ="city/getAllProvince"
  107 + var params ={}
  108 + app.post(url,params,"get").then((res)=>{
  109 + var nullData = {
  110 + code:'',
  111 + name:"全部省"
  112 + }
  113 + res.unshift(nullData)
  114 + console.log(res)
  115 + this.provinceList=res
  116 + }).catch((err)=>{
  117 + console.log(err)
  118 + })
  119 + },
  120 +
  121 + //市
  122 + getAllCity(){
  123 + var url = "city/getCity"
  124 + var params = {
  125 + province_id:this.province_id
  126 + }
  127 + app.post(url,params,"get").then((res)=>{
  128 + console.log(res)
  129 + this.cityList=res
  130 + }).catch((err)=>{
  131 + console.log(err)
  132 + })
  133 + },
  134 + },
  135 + onLoad(){
  136 + this.getAllProvince()
  137 + }
  138 +}
  139 +</script>
  140 +
  141 +<style lang="less">
  142 + .diquPopup{
  143 + font-size: 28rpx;
  144 + width: 686rpx;
  145 + height: 600rpx;
  146 + position: absolute;
  147 + top: 124rpx;
  148 + left: 50%;
  149 + transform: translate(-50%);
  150 + background-color: #fff;
  151 + padding: 22rpx 32rpx;
  152 + box-sizing: border-box;
  153 + z-index: 999;
  154 + box-shadow:0px 4px 4px rgba(0,0,0,0.06);
  155 + border-top: 1rpx solid rgba(249,249,249,1);
  156 + .item{
  157 + margin-bottom: 22rpx;
  158 + // height: 74rpx;
  159 + width: 170rpx;
  160 + }
  161 + .title{
  162 + margin-bottom: 20rpx;
  163 + }
  164 + .cont{
  165 + .colum{
  166 + width: 30%;
  167 + height: 500rpx;
  168 + }
  169 + display: flex;
  170 + height: 600rpx;
  171 + flex-direction: column;
  172 + flex-wrap: wrap;
  173 + justify-content: start;
  174 + }
  175 + }
  176 +.content{
  177 + background:rgba(249,249,249,1);
  178 + padding: 32rpx;
  179 + height: 100vh;
  180 + box-sizing: border-box;
  181 + .selectCard{
  182 + background-color: #fff;
  183 + border-radius:20rpx;
  184 + .item{
  185 + display: flex;
  186 + justify-content: space-between;
  187 + padding: 30rpx 32rpx;
  188 + // background-color: #fff;
  189 + border-bottom: 1rpx solid rgba(238,238,238,1);
  190 + font-size: 28rpx;
  191 + .selectBtn{
  192 + color:rgba(189,196,206,1);
  193 + .icon{
  194 + width: 13rpx;
  195 + height: 24rpx;
  196 + margin-left: 8rpx;
  197 + }
  198 + }
  199 + .inpt{
  200 + // height: 30rpx;
  201 + text-align: right;
  202 + // width: 250rpx;
  203 + }
  204 + }
  205 + }
  206 + .btn{
  207 + width:686rpx;
  208 + height:80rpx;
  209 + background:rgba(45,85,117,1);
  210 + opacity:1;
  211 + border-radius:8rpx;
  212 + color: #fff;
  213 + line-height: 80rpx;
  214 + text-align: center;
  215 + font-size: 28rpx;
  216 + position: absolute;
  217 + bottom: 32rpx;
  218 + }
  219 + .popup{
  220 + width: 100%;
  221 + height: 100%;
  222 + background-color: rgba(0, 0, 0, 0.5);
  223 + position: fixed;
  224 + top: 0;
  225 + left: 0;
  226 + right: 0;
  227 + z-index: 999;
  228 + .card{
  229 + width: 628rpx;
  230 + height: 294rpx;
  231 + background-color: #fff;
  232 + position: absolute;
  233 + top: 50%;
  234 + left: 50%;
  235 + transform: translate(-50%,-50%);
  236 + display: flex;
  237 + flex-direction: column;
  238 + justify-content: space-between;
  239 + text-align: center;
  240 + padding: 40rpx 0;
  241 + box-sizing: border-box;
  242 + .title{
  243 + font-size: 32rpx;
  244 + }
  245 + .tips{
  246 + font-size: 24rpx;
  247 + }
  248 + .okBtn{
  249 + width:220rpx;
  250 + height:60rpx;
  251 + background:rgba(45,85,117,1);
  252 + opacity:1;
  253 + border-radius:8rpx;
  254 + text-align: center;
  255 + line-height: 60rpx;
  256 + color: #fff;
  257 + font-size: 28rpx;
  258 + margin: 0 auto;
  259 + }
  260 + }
  261 +
  262 + }
  263 +}
  264 +</style>
  1 +<template>
  2 + <view class="content">
  3 + <view class="studentMsg">
  4 + <view class="item">
  5 + <view class="title">姓名</view>
  6 + <input type="text" v-model="username" class="inpt" placeholder="请输入姓名" placeholder-style="color:rgba(189,196,206,1);font-size:28rpx;">
  7 + </view>
  8 + <view class="item">
  9 + <view class="title">邮箱</view>
  10 + <input type="text" v-model="email" class="inpt" placeholder="请输入邮箱" placeholder-style="color:rgba(189,196,206,1);font-size:28rpx;">
  11 + </view>
  12 + <view class="item" style="border-bottom:none">
  13 + <view class="title">头像</view>
  14 + <image @click="upload" class="photo" :src="isUpload ? image : '../../static/touxiang_img@2x.png'"></image>
  15 + </view>
  16 + </view>
  17 + <view class="schoolTitle">高中信息</view>
  18 + <view class="studentMsg">
  19 + <view class="item" @click="selhigh">
  20 + <view class="title">高中</view>
  21 + <view class="selectBtn">{{isHighShow? name : '请选择就读高中'}}<image class="icon" src="../../static/zhuandao_icon@2x.png"></image></view>
  22 + </view>
  23 + <view class="item">
  24 + <view class="title">毕业年份</view>
  25 + <!-- <view class="selectBtn">请选择毕业年份<image class="icon" src="../../static/zhuandao_icon@2x.png"></image></view> -->
  26 + <view @click="selDate" style="display: flex;justify-content: space-between;align-items: center;">
  27 + <picker mode="date" :value="date" start="2000-01-01" @change="bindTimeChange">
  28 + <view class="selectBtn">{{isDateShow? date : '请选择毕业年份'}}</view>
  29 + </picker>
  30 + <image class="icon" src="../../static/zhuandao_icon@2x.png"></image>
  31 + </view>
  32 + </view>
  33 + <view class="item" @click="subPopupShow">
  34 + <view class="title">选考科目</view>
  35 + <view class="selectBtn">{{subid.toString()!='' ? subname.toString() : "请选择选考科目"}}<image class="icon" src="../../static/zhuandao_icon@2x.png"></image></view>
  36 + </view>
  37 + <view class="item" style="border-bottom:none" @click="stylePopupShow">
  38 + <view class="title">升学方式</view>
  39 + <view class="selectBtn">{{isupnameshow? upname : "请选择升学方式"}}<image class="icon" src="../../static/zhuandao_icon@2x.png"></image></view>
  40 + </view>
  41 + </view>
  42 + <view class="schoolTitle">大学信息</view>
  43 + <view class="studentMsg">
  44 + <view class="item" @click="selcollege">
  45 + <view class="title">就读大学</view>
  46 + <view class="selectBtn">{{isNameShow? collegename : '请选择就读大学'}}<image class="icon" src="../../static/zhuandao_icon@2x.png"></image></view>
  47 + </view>
  48 + <view class="item">
  49 + <view class="title">所属学院</view>
  50 + <view class="selectBtn" @click="tocollege">{{iscollgegshow? academyname : '请选择所属学院' }}<image class="icon" src="../../static/zhuandao_icon@2x.png"></image></view>
  51 + </view>
  52 + <view class="item" style="border-bottom:none" @click="tomajor">
  53 + <view class="title">就读专业</view>
  54 + <view class="selectBtn">{{ismajorshow? academyname : '请选择所属专业' }}<image class="icon" src="../../static/zhuandao_icon@2x.png"></image></view>
  55 + </view>
  56 + </view>
  57 + <view class="okBtn" @click="collegeregister">注册</view>
  58 + <view class="subPopup" v-if="isSubPopupShow">
  59 + <view class="selectCard">
  60 + <view class="buttonBox">
  61 + <view class="closeBtn" @click="subPopupHide">取消</view>
  62 + <view class="confimBtn" @click="subPopupHide">确定</view>
  63 + </view>
  64 + <view class="subBox">
  65 + <view class="subject" @click="selsub" :class="{active:subid.indexOf(item.id)!=-1}" v-for="(item,index) in sublist" :key="index" :data-id="item.id" :data-name="item.name">{{item.name}}</view>
  66 + </view>
  67 + </view>
  68 + </view>
  69 + <view class="stylePopup" v-if="isStylePopupShow">
  70 + <view class="styleCard">
  71 + <view class="buttonBox">
  72 + <view class="closeBtn" @click="stylePopupHide">取消</view>
  73 + <view class="confimBtn" @click="stylePopupHide">确定</view>
  74 + </view>
  75 + <view class="subBox">
  76 + <view class="subject" :class="{active:upid==item.id}" @click="selup" v-for="(item,index) in uplist" :key="index" :data-id="item.id" :data-name="item.name">{{item.name}}</view>
  77 + </view>
  78 + </view>
  79 + </view>
  80 + </view>
  81 +</template>
  82 +
  83 +<script>
  84 + import app from "../../App.vue"
  85 +
  86 +export default {
  87 + data(){
  88 + return{
  89 + isSubPopupShow:false,
  90 + isStylePopupShow:false,
  91 + username:'',
  92 + image:'',
  93 + isUpload:false,
  94 + date: '请选择毕业年份',
  95 + isDateShow: false,
  96 + uplist:[],
  97 + upid:'1',
  98 + subid:[],
  99 + sublist:[],
  100 + collegename:'请选择就读大学',
  101 + isNameShow:false,
  102 + isHighShow:false,
  103 + name:'请选择就读高中',
  104 + subname:[],
  105 + issubnameshow:false,
  106 + upname:'请选择升学方式',
  107 + isupnameshow:false,
  108 + school_id:'',
  109 + uni_id:'',
  110 + academyname:'请选择所属学院',
  111 + iscollgegshow:false,
  112 + majorname:'请选择所属专业',
  113 + ismajorshow:false,
  114 + email:'',
  115 + majorid:'',
  116 + academyid:'',
  117 + chuanimg:''
  118 +
  119 + }
  120 + },
  121 + methods:{
  122 + selDate(){
  123 + this.isDateShow=true
  124 + },
  125 + subPopupShow(){
  126 + this.isSubPopupShow=true
  127 + },
  128 + subPopupHide(){
  129 + this.isSubPopupShow=false
  130 + },
  131 + stylePopupShow(){
  132 + this.isStylePopupShow=true
  133 + },
  134 + stylePopupHide(){
  135 + this.isStylePopupShow=false
  136 + },
  137 + // toSchoolmate(){
  138 +
  139 + // wx.navigateTo({
  140 + // url: "/pages/schoolmate/schoolmate?type="+2
  141 + // })
  142 + // },
  143 + upload(){
  144 + var that = this;
  145 + uni.chooseImage({
  146 + count: 1,
  147 + sizeType: ['original', 'compressed'], //可以指定是原图还是压缩图,默认二者都有
  148 + sourceType: ['album'], //从相册选择
  149 + success: function (res) {
  150 + const tempFilePaths = res.tempFilePaths;
  151 + that.image = tempFilePaths[0];
  152 + app.upload('image',res.tempFilePaths[0],"post").then((res)=>{
  153 + // let newimage=that.image
  154 + that.image=res.url;
  155 + that.chuanimg=res.kurl
  156 + console.log(res)
  157 + console.log(that.image)
  158 + console.log(res.url)
  159 + // newimage.push(res.url)
  160 + that.isUpload=true
  161 + }).catch((err)=>{
  162 + console.log(err)
  163 + })
  164 + // console.log("tempFilePaths[0]",tempFilePaths[0]) //能够打印出选中的图片
  165 + // console.log(res)
  166 + // that.head_image=tempFilePaths[0]
  167 + // that.iconcheck = 1;//点击后图片更改状态由0变成1
  168 + },
  169 + error : function(e){
  170 + console.log(e);
  171 + }
  172 + });
  173 + },
  174 + bindTimeChange: function(e) {
  175 + this.date = e.target.value
  176 + },
  177 + getUpType(){
  178 + var that = this
  179 + var url = "university/getAllUp"
  180 + var params = {}
  181 + app.post(url,params,"get").then((res)=>{
  182 + console.log(res)
  183 + that.uplist=res
  184 + }).catch((err)=>{
  185 + console.log(err)
  186 + })
  187 + },
  188 + getAllSub(){
  189 + var that=this
  190 + var url = "university/listSubject"
  191 + var params ={}
  192 + app.post(url,params,"get").then((res)=>{
  193 + that.sublist=res
  194 + console.log(res)
  195 + }).catch((err)=>{
  196 + console.log(err)
  197 + })
  198 + },
  199 + selup(e){
  200 + this.isupnameshow=true
  201 + console.log(e.currentTarget.dataset)
  202 + this.upid=e.currentTarget.dataset.id
  203 + this.upname=e.currentTarget.dataset.name
  204 + },
  205 + selsub(e){
  206 + Array.prototype.remove = function(val) {
  207 + var index = this.indexOf(val);
  208 + if (index > -1) {
  209 + this.splice(index, 1);
  210 + }
  211 + };
  212 + this.issubnameshow=true
  213 + if(this.subid.indexOf(e.currentTarget.dataset.id)!=-1){
  214 + this.subid.remove(e.currentTarget.dataset.id)
  215 + this.subname.remove(e.currentTarget.dataset.name)
  216 + }else{
  217 + this.subid.push(e.currentTarget.dataset.id)
  218 + this.subname.push(e.currentTarget.dataset.name)
  219 + }
  220 + console.log(this.subid)
  221 +
  222 + },
  223 + selcollege(){
  224 + this.isNameShow=true
  225 + uni.navigateTo({
  226 + url:'./selectCollege'
  227 + })
  228 + },
  229 + selhigh(){
  230 + this.isHighShow=true
  231 + uni.navigateTo({
  232 + url:'./selectSchool'
  233 + })
  234 + },
  235 + tocollege(){
  236 + this.iscollgegshow=true
  237 + var school_id = this.uni_id
  238 + console.log(school_id)
  239 + uni.navigateTo({
  240 + url:'./selectAcademy?uni_id='+school_id
  241 + })
  242 + },
  243 + tomajor(){
  244 + this.ismajorshow=true
  245 +
  246 + uni.navigateTo({
  247 + url:'./selectMajor'
  248 + })
  249 + },
  250 + collegeregister(){
  251 + var that = this
  252 + if(that.username==''){
  253 + uni.showToast({
  254 + title:"姓名不能为空",
  255 + icon:"none"
  256 + })
  257 + return false
  258 + }
  259 + var reg = /^\w+((-\w+)|(\.\w+))*\@[A-Za-z0-9]+((\.|-)[A-Za-z0-9]+)*\.[A-Za-z0-9]+$/ ;
  260 + if(!reg.test(that.email)){
  261 + uni.showToast({
  262 + title:"请输入正确邮箱",
  263 + icon:"none"
  264 + })
  265 + return false
  266 + }
  267 + if(that.image==''){
  268 + uni.showToast({
  269 + title:"请选择头像",
  270 + icon:"none"
  271 + })
  272 + return false
  273 + }
  274 + if(that.name=='请选择就读高中'){
  275 + uni.showToast({
  276 + title:"请选择高中",
  277 + icon:"none"
  278 + })
  279 + return false
  280 + }
  281 + if(that.date=='请选择毕业年份'){
  282 + uni.showToast({
  283 + title:"请选择毕业年份",
  284 + icon:"none"
  285 + })
  286 + return false
  287 + }
  288 + if(that.subname=='请选择选考科目'){
  289 + uni.showToast({
  290 + title:"请选择选考科目",
  291 + icon:"none"
  292 + })
  293 + return false
  294 + }
  295 + if(that.upname=='请选择升学方式'){
  296 + uni.showToast({
  297 + title:"请选择升学方式",
  298 + icon:"none"
  299 + })
  300 + return false
  301 + }
  302 + if(that.collegename=='请选择就读大学'){
  303 + uni.showToast({
  304 + title:"请选择就读大学",
  305 + icon:"none"
  306 + })
  307 + return false
  308 + }
  309 + if(that.academyname=='请选择所属学院'){
  310 + uni.showToast({
  311 + title:"请选择所属学院",
  312 + icon:"none"
  313 + })
  314 + return false
  315 + }
  316 + if(that.majorname=='请选择所属专业'){
  317 + uni.showToast({
  318 + title:"请选择所属专业",
  319 + icon:"none"
  320 + })
  321 + return false
  322 + }
  323 + var url = "register/register"
  324 + var token = uni.getStorageSync('token')
  325 + var params = {
  326 + token:token,
  327 + level:2,
  328 + nickname:that.username,
  329 + head_image:that.chuanimg,
  330 + school_id:that.school_id,
  331 + email:that.email,
  332 + endtime:that.date,
  333 + subject_ids:that.subid.toString(),
  334 + up_id:that.upid,
  335 + university_id:that.uni_id,
  336 + graduated_id:that.majorid,
  337 + college_id:that.academyid
  338 +
  339 + }
  340 + app.post(url,params,"post").then((res)=>{
  341 + console.log(res)
  342 + // console.log(res)
  343 + uni.showToast({
  344 + title:"注册成功",
  345 + icon:"none"
  346 + })
  347 + setTimeout(() => {
  348 + uni.navigateTo({
  349 + url: "/pages/schoolmate/schoolmate?type="+2
  350 + })
  351 + }, 1500);
  352 + }).catch((err)=>{
  353 + console.log(err)
  354 + if(err.code==0){
  355 + uni.showToast({
  356 + title:err.msg,
  357 + icon:'none'
  358 + })
  359 + }
  360 +
  361 + })
  362 + }
  363 +
  364 + },
  365 + onLoad(){
  366 + this.getUpType()
  367 + this.getAllSub()
  368 + }
  369 +
  370 +}
  371 +</script>
  372 +
  373 +<style lang="less">
  374 +.content{
  375 + padding: 32rpx;
  376 + background:rgba(249,249,249,1);
  377 + font-size: 28rpx;
  378 + .studentMsg{
  379 + background-color: #fff;
  380 + padding: 0rpx 32rpx;
  381 + border-radius:20rpx;
  382 + .item{
  383 + height: 114rpx;
  384 + display: flex;
  385 + justify-content: space-between;
  386 + align-items: center;
  387 + border-bottom: 1rpx solid rgba(238,238,238,1);
  388 + font-size: 28rpx;
  389 + .title{
  390 + // line-height: 114px;
  391 + padding: 30rpx 0;
  392 + // box-sizing: border-box;
  393 + }
  394 + .selectBtn{
  395 + color:rgba(189,196,206,1);
  396 + line-height: 114rpx;
  397 +
  398 + }
  399 + .icon{
  400 + width: 13rpx;
  401 + height: 24rpx;
  402 + margin-left: 8rpx;
  403 + }
  404 + .inpt{
  405 + height: 114rpx;
  406 + text-align: right;
  407 + // width: 250rpx;
  408 + }
  409 + .photo{
  410 + width: 64rpx;
  411 + height: 64rpx;
  412 + margin-top: 20rpx;
  413 + border-radius: 50%;
  414 + }
  415 + }
  416 + }
  417 + .schoolTitle{
  418 + font-size:32rpx;
  419 + color:rgba(45,85,117,1);
  420 + margin-top: 44rpx;
  421 + margin-bottom: 12rpx;
  422 + }
  423 + .okBtn{
  424 + width:686rpx;
  425 + height:80rpx;
  426 + background:rgba(45,85,117,1);
  427 + opacity:1;
  428 + border-radius:8rpx;
  429 + font-size: 28rpx;
  430 + color: #fff;
  431 + line-height: 80rpx;
  432 + text-align: center;
  433 + margin-top: 56rpx;
  434 + }
  435 + .subPopup{
  436 + width: 100%;
  437 + height: 100%;
  438 + background-color: rgba(0, 0, 0, 0.5);
  439 + position: fixed;
  440 + top: 0;
  441 + left: 0;
  442 + right: 0;
  443 + z-index: 999;
  444 + .selectCard{
  445 + width: 750rpx;
  446 + height: 426rpx;
  447 + background:rgba(255,255,255,1);
  448 + // opacity:1;
  449 + border-radius:20px 20px 0px 0px;
  450 + position: absolute;
  451 + bottom: 0;
  452 + .buttonBox{
  453 + display: flex;
  454 + justify-content: space-between;
  455 + padding: 28rpx 30rpx;
  456 + font-size: 28rpx;
  457 + .closeBtn{
  458 + color:rgba(140,145,152,1);
  459 + }
  460 + .confimBtn{
  461 + color:rgba(45,85,117,1);
  462 + }
  463 + }
  464 + .subBox{
  465 + display: flex;
  466 + flex-wrap: wrap;
  467 + justify-content: space-between;
  468 + padding: 16rpx 32rpx;
  469 + .active{
  470 + background:rgba(129,195,191,1);
  471 + border:2rpx solid rgba(129,195,191,1);
  472 + color: #fff;
  473 + }
  474 + }
  475 + .subject{
  476 + width:28%;
  477 + height:56rpx;
  478 + background: #fff;
  479 + border:1rpx solid rgba(6,18,30,1);
  480 + opacity:1;
  481 + border-radius:40rpx;
  482 + text-align: center;
  483 + line-height: 56rpx;
  484 + color:rgba(6,18,30,1);
  485 + font-size: 28rpx;
  486 + margin-bottom: 36rpx;
  487 + }
  488 + }
  489 + }
  490 + .stylePopup{
  491 + width: 100%;
  492 + height: 100%;
  493 + background-color: rgba(0, 0, 0, 0.5);
  494 + position: fixed;
  495 + top: 0;
  496 + left: 0;
  497 + right: 0;
  498 + z-index: 999;
  499 + .styleCard{
  500 + width: 750rpx;
  501 + height: 228rpx;
  502 + background:rgba(255,255,255,1);
  503 + // opacity:1;
  504 + border-radius:20px 20px 0px 0px;
  505 + position: absolute;
  506 + bottom: 0;
  507 + .buttonBox{
  508 + display: flex;
  509 + justify-content: space-between;
  510 + padding: 28rpx 30rpx;
  511 + font-size: 28rpx;
  512 + .closeBtn{
  513 + color:rgba(140,145,152,1);
  514 + }
  515 + .confimBtn{
  516 + color:rgba(45,85,117,1);
  517 + }
  518 + }
  519 + .subBox{
  520 + display: flex;
  521 + flex-wrap: wrap;
  522 + justify-content: space-around;
  523 + padding: 16rpx 32rpx;
  524 + .active{
  525 + background:rgba(129,195,191,1);
  526 + border:2rpx solid rgba(129,195,191,1);
  527 + color: #fff;
  528 + }
  529 + }
  530 + .subject{
  531 + width:28%;
  532 + height:56rpx;
  533 + background: #fff;
  534 + border:1rpx solid rgba(6,18,30,1);
  535 + opacity:1;
  536 + border-radius:40rpx;
  537 + text-align: center;
  538 + line-height: 56rpx;
  539 + color:rgba(6,18,30,1);
  540 + font-size: 28rpx;
  541 + margin-bottom: 36rpx;
  542 + }
  543 + }
  544 + }
  545 +}
  546 +</style>
  1 +<template>
  2 + <view class="content">
  3 + <view class="regMsg">
  4 + <view class="msgItem">
  5 + <view class="title">姓名</view>
  6 + <input type="text" class="inpt" v-model="nickname" placeholder="请填写姓名" placeholder-style="color:rgba(189,196,206,1);font-size:28rpx">
  7 + </view>
  8 + <view class="msgItem">
  9 + <view class="title">邮箱</view>
  10 + <input type="text" class="inpt" v-model="email" placeholder="请填写邮箱" placeholder-style="color:rgba(189,196,206,1);font-size:28rpx">
  11 + </view>
  12 + <view class="msgItem">
  13 + <view class="title">头像</view>
  14 + <view @click="upload">
  15 + <image class="photo" :src="isUpload ? image : '../../static/touxiang_img@2x.png'"></image>
  16 + </view>
  17 + </view>
  18 + <view class="msgItem" @click="selSchool">
  19 + <view class="title">高中</view>
  20 + <view class="select">{{isNameShow? name : '请选择高中'}}<image class="icon" src="../../static/zhuandao_icon@2x.png"></image></view>
  21 +
  22 + </view>
  23 + <view class="msgItem" style="border-bottom: none;">
  24 + <view class="title">入学年份</view>
  25 +
  26 + <view class="select" @click="selDate">
  27 + <picker mode="date" :value="date" start="2000-01-01" @change="bindTimeChange">
  28 + <view class="uni-input">{{isDateShow? date : '请选择入学年份'}}</view>
  29 + </picker>
  30 + <image class="icon" src="../../static/zhuandao_icon@2x.png"></image>
  31 + </view>
  32 + </view>
  33 + <!-- <view class="uni-title uni-common-pl">时间选择器</view> -->
  34 +
  35 + </view>
  36 + <view class="regBtn" @click="toSchool">注册</view>
  37 + </view>
  38 +</template>
  39 +
  40 +<script>
  41 + import app from "../../App.vue";
  42 +export default {
  43 +
  44 + data(){
  45 + return{
  46 + level:'1',
  47 + nickname:'',
  48 + name:'请选择高中',
  49 + image:'',
  50 + school_id:'',
  51 + email:'',
  52 + isUpload:false,
  53 + date: '请选择入学年份',
  54 + isDateShow: false,
  55 + isNameShow:false,
  56 + chuanimg:''
  57 + }
  58 + },
  59 + onLoad(options) {
  60 + console.log(options)
  61 + // this.school_id=options.school_id
  62 + },
  63 + methods:{
  64 + selDate(){
  65 + this.isDateShow=true
  66 + },
  67 + selSchool(){
  68 + this.isNameShow=true
  69 + uni.navigateTo({
  70 + url:'./selectSchool'
  71 + })
  72 + },
  73 + bindTimeChange: function(e) {
  74 + this.date = e.target.value
  75 + },
  76 + toSchool(){
  77 + var that=this
  78 + if(that.nickname==''){
  79 + uni.showToast({
  80 + title:"姓名不能为空",
  81 + icon:"none"
  82 + })
  83 + return false
  84 + }
  85 + var reg = /^\w+((-\w+)|(\.\w+))*\@[A-Za-z0-9]+((\.|-)[A-Za-z0-9]+)*\.[A-Za-z0-9]+$/ ;
  86 + if(!reg.test(that.email)){
  87 + uni.showToast({
  88 + title:"请输入正确邮箱",
  89 + icon:"none"
  90 + })
  91 + return false
  92 + }
  93 + if(that.image==''){
  94 + uni.showToast({
  95 + title:"请选择头像",
  96 + icon:"none"
  97 + })
  98 + return false
  99 + }
  100 + if(that.name=='请选择高中'){
  101 + uni.showToast({
  102 + title:"请选择高中",
  103 + icon:"none"
  104 + })
  105 + return false
  106 + }
  107 + if(that.date=='请选择入学年份'){
  108 + uni.showToast({
  109 + title:"请选择入学年份",
  110 + icon:"none"
  111 + })
  112 + return false
  113 + }
  114 + var url="register/register"
  115 +
  116 + var params={
  117 + level:that.level,
  118 + nickname:that.nickname,
  119 + head_image:that.chuanimg,
  120 + school_id:that.school_id,
  121 + email:that.email,
  122 + starttime:this.date
  123 +
  124 + }
  125 + app.post(url,params,"post").then((res)=>{
  126 + console.log(res)
  127 + uni.showToast({
  128 + title:"注册成功",
  129 + icon:"none"
  130 + })
  131 + setTimeout(() => {
  132 + uni.navigateTo({
  133 + url: "/pages/school/school?type="+1
  134 + })
  135 + }, 1500);
  136 +
  137 +
  138 + }).catch((err)=>{
  139 + console.log(err)
  140 + if(err.code==0){
  141 + uni.showToast({
  142 + title:err.msg,
  143 + icon:'none'
  144 + })
  145 + }
  146 + })
  147 + // wx.navigateTo({
  148 + // url:"../school/school"
  149 + // })
  150 +
  151 +
  152 +
  153 + },
  154 + upload(){
  155 + var that = this;
  156 + uni.chooseImage({
  157 + count: 1,
  158 + sizeType: ['original', 'compressed'], //可以指定是原图还是压缩图,默认二者都有
  159 + sourceType: ['album'], //从相册选择
  160 + success: function (res) {
  161 + const tempFilePaths = res.tempFilePaths;
  162 + that.image = tempFilePaths[0];
  163 + app.upload('image',res.tempFilePaths[0],"post").then((res)=>{
  164 + // let newimage=that.image
  165 + that.image=res.url;
  166 + that.chuanimg=res.kurl
  167 + console.log(res)
  168 + console.log(that.image)
  169 + console.log(res.url)
  170 + // newimage.push(res.url)
  171 + that.isUpload=true
  172 + }).catch((err)=>{
  173 + console.log(err)
  174 + })
  175 + // console.log("tempFilePaths[0]",tempFilePaths[0]) //能够打印出选中的图片
  176 + // console.log(res)
  177 + // that.head_image=tempFilePaths[0]
  178 + // that.iconcheck = 1;//点击后图片更改状态由0变成1
  179 + },
  180 + error : function(e){
  181 + console.log(e);
  182 + }
  183 + });
  184 + },
  185 + }
  186 +}
  187 +</script>
  188 +
  189 +<style lang="less">
  190 +page{
  191 + overflow-y:hidden;
  192 +}
  193 +.content{
  194 + background:rgba(249,249,249,1);
  195 + height: 100vh;
  196 + .regMsg{
  197 + margin: 32rpx auto;
  198 + width:686rpx;
  199 + height:528rpx;
  200 + background:rgba(255,255,255,1);
  201 + opacity:1;
  202 + border-radius:20rpx;
  203 + padding: 0 32rpx;
  204 + box-sizing: border-box;
  205 + .msgItem{
  206 + border-bottom: 1rpx solid rgba(238,238,238,1);
  207 + display: flex;
  208 + justify-content: space-between;
  209 + // text-align: center;
  210 + .title{
  211 + color:rgba(6,18,30,1);
  212 + font-size: 28rpx;
  213 + line-height: 105rpx;
  214 + }
  215 + .inpt{
  216 + text-align: right;
  217 + height: 105rpx;
  218 + font-size: 28rpx;
  219 + }
  220 + .photo{
  221 + width: 64rpx;
  222 + height: 64rpx;
  223 + margin-top: 20rpx;
  224 + border-radius: 50%;
  225 + }
  226 + .select{
  227 + font-size: 28rpx;
  228 + color:rgba(189,196,206,1);
  229 + height: 105rpx;
  230 + display: flex;
  231 + line-height: 105rpx;
  232 + align-items: center;
  233 + }
  234 + .icon{
  235 + width: 13rpx;
  236 + height: 24rpx;
  237 + margin-left: 8rpx;
  238 + }
  239 + }
  240 + }
  241 + .regBtn{
  242 + width:684rpx;
  243 + height:80rpx;
  244 + background:rgba(45,85,117,1);
  245 + opacity:1;
  246 + border-radius:8rpx;
  247 + color: #fff;
  248 + font-size: 28rpx;
  249 + line-height: 80rpx;
  250 + text-align: center;
  251 + // margin: 0 auto;
  252 + // margin-top: 600rpx;
  253 + position: absolute;
  254 + bottom: 84rpx;
  255 + left: 50%;
  256 + transform: translate(-50%);
  257 + }
  258 +}
  259 +</style>