@ -0,0 +1,23 @@
|
||||
.DS_Store
|
||||
node_modules/
|
||||
unpackage/
|
||||
dist/
|
||||
|
||||
# local env files
|
||||
.env.local
|
||||
.env.*.local
|
||||
|
||||
# Log files
|
||||
npm-debug.log*
|
||||
yarn-debug.log*
|
||||
yarn-error.log*
|
||||
|
||||
# Editor directories and files
|
||||
.project
|
||||
.idea
|
||||
.vscode
|
||||
*.suo
|
||||
*.ntvs*
|
||||
*.njsproj
|
||||
*.sln
|
||||
*.sw*
|
@ -0,0 +1,19 @@
|
||||
# kxmh-xhs
|
||||
|
||||
## Project setup
|
||||
```
|
||||
npm install
|
||||
```
|
||||
|
||||
### Compiles and hot-reloads for development
|
||||
```
|
||||
npm run serve
|
||||
```
|
||||
|
||||
### Compiles and minifies for production
|
||||
```
|
||||
npm run build
|
||||
```
|
||||
|
||||
### Customize configuration
|
||||
See [Configuration Reference](https://cli.vuejs.org/config/).
|
@ -0,0 +1,77 @@
|
||||
const webpack = require('webpack')
|
||||
const plugins = []
|
||||
|
||||
if (process.env.UNI_OPT_TREESHAKINGNG) {
|
||||
plugins.push(require('@dcloudio/vue-cli-plugin-uni-optimize/packages/babel-plugin-uni-api/index.js'))
|
||||
}
|
||||
|
||||
if (
|
||||
(
|
||||
process.env.UNI_PLATFORM === 'app-plus' &&
|
||||
process.env.UNI_USING_V8
|
||||
) ||
|
||||
(
|
||||
process.env.UNI_PLATFORM === 'h5' &&
|
||||
process.env.UNI_H5_BROWSER === 'builtin'
|
||||
)
|
||||
) {
|
||||
const path = require('path')
|
||||
|
||||
const isWin = /^win/.test(process.platform)
|
||||
|
||||
const normalizePath = path => (isWin ? path.replace(/\\/g, '/') : path)
|
||||
|
||||
const input = normalizePath(process.env.UNI_INPUT_DIR)
|
||||
try {
|
||||
plugins.push([
|
||||
require('@dcloudio/vue-cli-plugin-hbuilderx/packages/babel-plugin-console'),
|
||||
{
|
||||
file (file) {
|
||||
file = normalizePath(file)
|
||||
if (file.indexOf(input) === 0) {
|
||||
return path.relative(input, file)
|
||||
}
|
||||
return false
|
||||
}
|
||||
}
|
||||
])
|
||||
} catch (e) { }
|
||||
}
|
||||
|
||||
process.UNI_LIBRARIES = process.UNI_LIBRARIES || ['@dcloudio/uni-ui']
|
||||
process.UNI_LIBRARIES.forEach(libraryName => {
|
||||
plugins.push([
|
||||
'import',
|
||||
{
|
||||
'libraryName': libraryName,
|
||||
'customName': (name) => {
|
||||
return `${libraryName}/lib/${name}/${name}`
|
||||
}
|
||||
}
|
||||
])
|
||||
})
|
||||
|
||||
const config = {
|
||||
presets: [
|
||||
[
|
||||
'@vue/app',
|
||||
{
|
||||
modules: webpack.version[0] > 4 ? 'auto' : 'commonjs',
|
||||
useBuiltIns: process.env.UNI_PLATFORM === 'h5' ? 'usage' : 'entry'
|
||||
}
|
||||
]
|
||||
],
|
||||
plugins
|
||||
}
|
||||
|
||||
const UNI_H5_TEST = '**/@dcloudio/uni-h5/dist/index.umd.min.js'
|
||||
if (process.env.NODE_ENV === 'production') {
|
||||
config.overrides = [{
|
||||
test: UNI_H5_TEST,
|
||||
compact: true,
|
||||
}]
|
||||
} else {
|
||||
config.ignore = [UNI_H5_TEST]
|
||||
}
|
||||
|
||||
module.exports = config
|
@ -0,0 +1,9 @@
|
||||
{
|
||||
"compilerOptions": {
|
||||
"types": [
|
||||
"@dcloudio/types",
|
||||
"miniprogram-api-typings",
|
||||
"mini-types"
|
||||
]
|
||||
}
|
||||
}
|
@ -0,0 +1,114 @@
|
||||
{
|
||||
"name": "kxmh-xhs",
|
||||
"version": "0.1.0",
|
||||
"private": true,
|
||||
"scripts": {
|
||||
"serve": "npm run dev:h5",
|
||||
"build": "npm run build:h5",
|
||||
"build:app-plus": "cross-env NODE_ENV=production UNI_PLATFORM=app-plus vue-cli-service uni-build",
|
||||
"build:custom": "cross-env NODE_ENV=production uniapp-cli custom",
|
||||
"build:h5": "cross-env NODE_ENV=production UNI_PLATFORM=h5 vue-cli-service uni-build",
|
||||
"build:mp-360": "cross-env NODE_ENV=production UNI_PLATFORM=mp-360 vue-cli-service uni-build",
|
||||
"build:mp-alipay": "cross-env NODE_ENV=production UNI_PLATFORM=mp-alipay vue-cli-service uni-build",
|
||||
"build:mp-baidu": "cross-env NODE_ENV=production UNI_PLATFORM=mp-baidu vue-cli-service uni-build",
|
||||
"build:mp-jd": "cross-env NODE_ENV=production UNI_PLATFORM=mp-jd vue-cli-service uni-build",
|
||||
"build:mp-kuaishou": "cross-env NODE_ENV=production UNI_PLATFORM=mp-kuaishou vue-cli-service uni-build",
|
||||
"build:mp-lark": "cross-env NODE_ENV=production UNI_PLATFORM=mp-lark vue-cli-service uni-build",
|
||||
"build:mp-qq": "cross-env NODE_ENV=production UNI_PLATFORM=mp-qq vue-cli-service uni-build",
|
||||
"build:mp-toutiao": "cross-env NODE_ENV=production UNI_PLATFORM=mp-toutiao vue-cli-service uni-build",
|
||||
"build:mp-weixin": "cross-env NODE_ENV=production UNI_PLATFORM=mp-weixin vue-cli-service uni-build",
|
||||
"build:mp-xhs": "cross-env NODE_ENV=production UNI_PLATFORM=mp-xhs vue-cli-service uni-build",
|
||||
"build:quickapp-native": "cross-env NODE_ENV=production UNI_PLATFORM=quickapp-native vue-cli-service uni-build",
|
||||
"build:quickapp-webview": "cross-env NODE_ENV=production UNI_PLATFORM=quickapp-webview vue-cli-service uni-build",
|
||||
"build:quickapp-webview-huawei": "cross-env NODE_ENV=production UNI_PLATFORM=quickapp-webview-huawei vue-cli-service uni-build",
|
||||
"build:quickapp-webview-union": "cross-env NODE_ENV=production UNI_PLATFORM=quickapp-webview-union vue-cli-service uni-build",
|
||||
"dev:app-plus": "cross-env NODE_ENV=development UNI_PLATFORM=app-plus vue-cli-service uni-build --watch",
|
||||
"dev:custom": "cross-env NODE_ENV=development uniapp-cli custom",
|
||||
"dev:h5": "cross-env NODE_ENV=development UNI_PLATFORM=h5 vue-cli-service uni-serve",
|
||||
"dev:mp-360": "cross-env NODE_ENV=development UNI_PLATFORM=mp-360 vue-cli-service uni-build --watch",
|
||||
"dev:mp-alipay": "cross-env NODE_ENV=development UNI_PLATFORM=mp-alipay vue-cli-service uni-build --watch",
|
||||
"dev:mp-baidu": "cross-env NODE_ENV=development UNI_PLATFORM=mp-baidu vue-cli-service uni-build --watch",
|
||||
"dev:mp-jd": "cross-env NODE_ENV=development UNI_PLATFORM=mp-jd vue-cli-service uni-build --watch",
|
||||
"dev:mp-kuaishou": "cross-env NODE_ENV=development UNI_PLATFORM=mp-kuaishou vue-cli-service uni-build --watch",
|
||||
"dev:mp-lark": "cross-env NODE_ENV=development UNI_PLATFORM=mp-lark vue-cli-service uni-build --watch",
|
||||
"dev:mp-qq": "cross-env NODE_ENV=development UNI_PLATFORM=mp-qq vue-cli-service uni-build --watch",
|
||||
"dev:mp-toutiao": "cross-env NODE_ENV=development UNI_PLATFORM=mp-toutiao vue-cli-service uni-build --watch",
|
||||
"dev:mp-weixin": "cross-env NODE_ENV=development UNI_PLATFORM=mp-weixin vue-cli-service uni-build --watch",
|
||||
"dev:mp-xhs": "cross-env NODE_ENV=development UNI_PLATFORM=mp-xhs vue-cli-service uni-build --watch",
|
||||
"dev:quickapp-native": "cross-env NODE_ENV=development UNI_PLATFORM=quickapp-native vue-cli-service uni-build --watch",
|
||||
"dev:quickapp-webview": "cross-env NODE_ENV=development UNI_PLATFORM=quickapp-webview vue-cli-service uni-build --watch",
|
||||
"dev:quickapp-webview-huawei": "cross-env NODE_ENV=development UNI_PLATFORM=quickapp-webview-huawei vue-cli-service uni-build --watch",
|
||||
"dev:quickapp-webview-union": "cross-env NODE_ENV=development UNI_PLATFORM=quickapp-webview-union vue-cli-service uni-build --watch",
|
||||
"info": "node node_modules/@dcloudio/vue-cli-plugin-uni/commands/info.js",
|
||||
"serve:quickapp-native": "node node_modules/@dcloudio/uni-quickapp-native/bin/serve.js",
|
||||
"test:android": "cross-env UNI_PLATFORM=app-plus UNI_OS_NAME=android jest -i",
|
||||
"test:h5": "cross-env UNI_PLATFORM=h5 jest -i",
|
||||
"test:ios": "cross-env UNI_PLATFORM=app-plus UNI_OS_NAME=ios jest -i",
|
||||
"test:mp-baidu": "cross-env UNI_PLATFORM=mp-baidu jest -i",
|
||||
"test:mp-weixin": "cross-env UNI_PLATFORM=mp-weixin jest -i"
|
||||
},
|
||||
"dependencies": {
|
||||
"@dcloudio/uni-app": "^2.0.1-alpha-36820221027001",
|
||||
"@dcloudio/uni-app-plus": "^2.0.1-alpha-36820221027001",
|
||||
"@dcloudio/uni-h5": "^2.0.1-alpha-36820221027001",
|
||||
"@dcloudio/uni-helper-json": "*",
|
||||
"@dcloudio/uni-i18n": "^2.0.1-alpha-36820221027001",
|
||||
"@dcloudio/uni-mp-360": "^2.0.1-alpha-36820221027001",
|
||||
"@dcloudio/uni-mp-alipay": "^2.0.1-alpha-36820221027001",
|
||||
"@dcloudio/uni-mp-baidu": "^2.0.1-alpha-36820221027001",
|
||||
"@dcloudio/uni-mp-jd": "^2.0.1-alpha-36820221027001",
|
||||
"@dcloudio/uni-mp-kuaishou": "^2.0.1-alpha-36820221027001",
|
||||
"@dcloudio/uni-mp-lark": "^2.0.1-alpha-36820221027001",
|
||||
"@dcloudio/uni-mp-qq": "^2.0.1-alpha-36820221027001",
|
||||
"@dcloudio/uni-mp-toutiao": "^2.0.1-alpha-36820221027001",
|
||||
"@dcloudio/uni-mp-vue": "^2.0.1-alpha-36820221027001",
|
||||
"@dcloudio/uni-mp-weixin": "^2.0.1-alpha-36820221027001",
|
||||
"@dcloudio/uni-mp-xhs": "^2.0.1-alpha-36820221027001",
|
||||
"@dcloudio/uni-quickapp-native": "^2.0.1-alpha-36820221027001",
|
||||
"@dcloudio/uni-quickapp-webview": "^2.0.1-alpha-36820221027001",
|
||||
"@dcloudio/uni-stacktracey": "^2.0.1-alpha-36820221027001",
|
||||
"@dcloudio/uni-stat": "^2.0.1-alpha-36820221027001",
|
||||
"@vue/shared": "^3.0.0",
|
||||
"core-js": "^3.8.3",
|
||||
"flyio": "^0.6.2",
|
||||
"regenerator-runtime": "^0.12.1",
|
||||
"uview-ui": "^2.0.35",
|
||||
"vue": "^2.6.14",
|
||||
"vuex": "^3.2.0"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@babel/runtime": "~7.17.9",
|
||||
"@dcloudio/types": "^3.0.4",
|
||||
"@dcloudio/uni-automator": "^2.0.1-alpha-36820221027001",
|
||||
"@dcloudio/uni-cli-i18n": "^2.0.1-alpha-36820221027001",
|
||||
"@dcloudio/uni-cli-shared": "^2.0.1-alpha-36820221027001",
|
||||
"@dcloudio/uni-migration": "^2.0.1-alpha-36820221027001",
|
||||
"@dcloudio/uni-template-compiler": "^2.0.1-alpha-36820221027001",
|
||||
"@dcloudio/vue-cli-plugin-hbuilderx": "^2.0.1-alpha-36820221027001",
|
||||
"@dcloudio/vue-cli-plugin-uni": "^2.0.1-alpha-36820221027001",
|
||||
"@dcloudio/vue-cli-plugin-uni-optimize": "^2.0.1-alpha-36820221027001",
|
||||
"@dcloudio/webpack-uni-mp-loader": "^2.0.1-alpha-36820221027001",
|
||||
"@dcloudio/webpack-uni-pages-loader": "^2.0.1-alpha-36820221027001",
|
||||
"@vue/cli-plugin-babel": "~5.0.0",
|
||||
"@vue/cli-service": "~5.0.0",
|
||||
"babel-plugin-import": "^1.11.0",
|
||||
"babel-plugin-syntax-dynamic-import": "^6.18.0",
|
||||
"cross-env": "^7.0.2",
|
||||
"jest": "^25.4.0",
|
||||
"mini-types": "*",
|
||||
"miniprogram-api-typings": "*",
|
||||
"postcss-comment": "^2.0.0",
|
||||
"sass": "^1.55.0",
|
||||
"vue-template-compiler": "^2.6.14"
|
||||
},
|
||||
"browserslist": [
|
||||
"Android >= 4.4",
|
||||
"ios >= 9"
|
||||
],
|
||||
"resolutions": {
|
||||
"@babel/runtime": "~7.17.9"
|
||||
},
|
||||
"uni-app": {
|
||||
"scripts": {}
|
||||
}
|
||||
}
|
@ -0,0 +1,27 @@
|
||||
const path = require('path')
|
||||
const webpack = require('webpack')
|
||||
const config = {
|
||||
parser: require('postcss-comment'),
|
||||
plugins: [
|
||||
require('postcss-import')({
|
||||
resolve (id, basedir, importOptions) {
|
||||
if (id.startsWith('~@/')) {
|
||||
return path.resolve(process.env.UNI_INPUT_DIR, id.substr(3))
|
||||
} else if (id.startsWith('@/')) {
|
||||
return path.resolve(process.env.UNI_INPUT_DIR, id.substr(2))
|
||||
} else if (id.startsWith('/') && !id.startsWith('//')) {
|
||||
return path.resolve(process.env.UNI_INPUT_DIR, id.substr(1))
|
||||
}
|
||||
return id
|
||||
}
|
||||
}),
|
||||
require('autoprefixer')({
|
||||
remove: process.env.UNI_PLATFORM !== 'h5'
|
||||
}),
|
||||
require('@dcloudio/vue-cli-plugin-uni/packages/postcss')
|
||||
]
|
||||
}
|
||||
if (webpack.version[0] > 4) {
|
||||
delete config.parser
|
||||
}
|
||||
module.exports = config
|
@ -0,0 +1,11 @@
|
||||
{
|
||||
"description": "项目配置文件",
|
||||
"setting": {
|
||||
"urlCheck": true,
|
||||
"minified": true
|
||||
},
|
||||
"compileType": "miniprogram",
|
||||
"libVersion": "3.34.2",
|
||||
"appid": "63427b653abf67000102aea8",
|
||||
"projectname": "kxmh-xhs"
|
||||
}
|
@ -0,0 +1,25 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="zh-CN">
|
||||
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<meta http-equiv="X-UA-Compatible" content="IE=edge">
|
||||
<title>
|
||||
<%= htmlWebpackPlugin.options.title %>
|
||||
</title>
|
||||
<script>
|
||||
var coverSupport = 'CSS' in window && typeof CSS.supports === 'function' && (CSS.supports('top: env(a)') || CSS.supports('top: constant(a)'))
|
||||
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' : '') + '" />')
|
||||
</script>
|
||||
<link rel="stylesheet" href="<%= BASE_URL %>static/index.<%= VUE_APP_INDEX_CSS_HASH %>.css" />
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<noscript>
|
||||
<strong>Please enable JavaScript to continue.</strong>
|
||||
</noscript>
|
||||
<div id="app"></div>
|
||||
<!-- built files will be auto injected -->
|
||||
</body>
|
||||
|
||||
</html>
|
@ -0,0 +1,10 @@
|
||||
import Vue from 'vue'
|
||||
declare module "vue/types/options" {
|
||||
type Hooks = App.AppInstance & Page.PageInstance;
|
||||
interface ComponentOptions<V extends Vue> extends Hooks {
|
||||
/**
|
||||
* 组件类型
|
||||
*/
|
||||
mpType?: string;
|
||||
}
|
||||
}
|
@ -0,0 +1,4 @@
|
||||
declare module "*.vue" {
|
||||
import Vue from 'vue'
|
||||
export default Vue
|
||||
}
|
@ -0,0 +1,7 @@
|
||||
// 测试
|
||||
// const host ='https://mini.kaixinguopiao.cn'
|
||||
// 正式
|
||||
const host ='https://mm.kaixinguopiao.com'
|
||||
module.exports={
|
||||
host
|
||||
}
|
@ -0,0 +1,145 @@
|
||||
const router_list = [
|
||||
{
|
||||
id: 1,
|
||||
router_name: "pages/index/index/index",
|
||||
},
|
||||
{
|
||||
id: 2,
|
||||
router_name: "pages/user/login/login",
|
||||
},
|
||||
{
|
||||
id: 3,
|
||||
router_name: "pages/user/user_index/user",
|
||||
|
||||
},
|
||||
{
|
||||
id: 4,
|
||||
router_name: "pages/opera/activity_topics/topics",
|
||||
},
|
||||
{
|
||||
id: 5,
|
||||
router_name: "pages/make_order/choose_sit/choose_sit",
|
||||
},
|
||||
{
|
||||
id: 6,
|
||||
router_name: "pages/make_order/coupon/coupon",
|
||||
},
|
||||
{
|
||||
id: 7,
|
||||
router_name: "pages/opera/opera/opera_IP",
|
||||
},
|
||||
{
|
||||
id: 8,
|
||||
router_name: "pages/user/my_show/finished_show/finished_show",
|
||||
},
|
||||
{
|
||||
id: 9,
|
||||
router_name: "pages/user/my_show/wanted_show/wanted_show",
|
||||
},
|
||||
{
|
||||
id: 10,
|
||||
router_name: "pages/user/my_order/my_order",
|
||||
},
|
||||
{
|
||||
id: 11,
|
||||
router_name: "pages/user/order_detail/order_detail",
|
||||
},
|
||||
{
|
||||
id: 12,
|
||||
router_name: "pages/opera/IP_more/IP_more",
|
||||
},
|
||||
{
|
||||
id: 13,
|
||||
router_name: "pages/opera/IP_detail/IP_detail",
|
||||
},
|
||||
{
|
||||
id: 14,
|
||||
router_name: "pages/make_order/make_order/make_order",
|
||||
},
|
||||
{
|
||||
id: 15,
|
||||
router_name: "pages/make_order/random_sit/random_sit",
|
||||
},
|
||||
{
|
||||
id: 16,
|
||||
router_name: "pages/opera/show/show_detail",
|
||||
},
|
||||
{
|
||||
id: 17,
|
||||
router_name: "pages/index/search/search",
|
||||
},
|
||||
{
|
||||
id: 18,
|
||||
router_name: "pages/user/invoice/invoice_index/invoice_index",
|
||||
},
|
||||
{
|
||||
id: 19,
|
||||
router_name: "pages/user/invoice/invoice_edit/invoice_edit_newMake",
|
||||
},
|
||||
{
|
||||
id: 20,
|
||||
router_name: "pages/user/invoice/invoice_edit/invoice_edit_content",
|
||||
},
|
||||
{
|
||||
id: 21,
|
||||
router_name: "pages/user/invoice/invoice_edit/invoice_edit",
|
||||
},
|
||||
{
|
||||
id: 22,
|
||||
router_name: "pages/user/invoice/invoice_history/invoice_history",
|
||||
},
|
||||
{
|
||||
id: 23,
|
||||
router_name: "pages/user/invoice/my_invoice/my_invoice",
|
||||
},
|
||||
{
|
||||
id: 24,
|
||||
router_name: "pages/user/invoice/make_invoice/make_invoice",
|
||||
},
|
||||
{
|
||||
id: 25,
|
||||
router_name: "pages/user/discount/discount/discount",
|
||||
},
|
||||
{
|
||||
id: 26,
|
||||
router_name: "pages/user/discount/coupons/coupons",
|
||||
},
|
||||
{
|
||||
id: 27,
|
||||
router_name: "pages/user/discount/discount_ex/discount_ex",
|
||||
},
|
||||
{
|
||||
id: 28,
|
||||
router_name: "pages/user/discount/discount_avilable/discount_avilable",
|
||||
},
|
||||
{
|
||||
id: 29,
|
||||
router_name: "pages/user/auto_service/auto_service",
|
||||
},
|
||||
{
|
||||
id: 30,
|
||||
router_name: "pages/user/wallet/wallet/wallet",
|
||||
},
|
||||
{
|
||||
id: 31,
|
||||
router_name: "pages/user/wallet/code_exchange/code_exchange",
|
||||
},
|
||||
{
|
||||
id: 32,
|
||||
router_name: "pages/user/viewer_list/viewer_list",
|
||||
},
|
||||
{
|
||||
id: 33,
|
||||
router_name: "pages/index/calendar/calendar",
|
||||
|
||||
},
|
||||
{
|
||||
id: 34,
|
||||
router_name: "pages/index/city/selectcity"
|
||||
|
||||
|
||||
},
|
||||
]
|
||||
module.exports = {
|
||||
router_list
|
||||
}
|
@ -0,0 +1,84 @@
|
||||
{
|
||||
"name" : "kxmh-xhs",
|
||||
"appid" : "__UNI__4631F68",
|
||||
"description" : "",
|
||||
"versionName" : "1.0.0",
|
||||
"versionCode" : "100",
|
||||
"transformPx" : false,
|
||||
"app-plus" : {
|
||||
/* 5+App特有相关 */
|
||||
"usingComponents" : true,
|
||||
"nvueStyleCompiler" : "uni-app",
|
||||
"compilerVersion" : 3,
|
||||
"splashscreen" : {
|
||||
"alwaysShowBeforeRender" : true,
|
||||
"waiting" : true,
|
||||
"autoclose" : true,
|
||||
"delay" : 0
|
||||
},
|
||||
"modules" : {},
|
||||
/* 模块配置 */
|
||||
"distribute" : {
|
||||
/* 应用发布信息 */
|
||||
"android" : {
|
||||
/* android打包配置 */
|
||||
"permissions" : [
|
||||
"<uses-permission android:name=\"android.permission.CHANGE_NETWORK_STATE\"/>",
|
||||
"<uses-permission android:name=\"android.permission.MOUNT_UNMOUNT_FILESYSTEMS\"/>",
|
||||
"<uses-permission android:name=\"android.permission.READ_CONTACTS\"/>",
|
||||
"<uses-permission android:name=\"android.permission.VIBRATE\"/>",
|
||||
"<uses-permission android:name=\"android.permission.READ_LOGS\"/>",
|
||||
"<uses-permission android:name=\"android.permission.ACCESS_WIFI_STATE\"/>",
|
||||
"<uses-feature android:name=\"android.hardware.camera.autofocus\"/>",
|
||||
"<uses-permission android:name=\"android.permission.WRITE_CONTACTS\"/>",
|
||||
"<uses-permission android:name=\"android.permission.ACCESS_NETWORK_STATE\"/>",
|
||||
"<uses-permission android:name=\"android.permission.CAMERA\"/>",
|
||||
"<uses-permission android:name=\"android.permission.RECORD_AUDIO\"/>",
|
||||
"<uses-permission android:name=\"android.permission.GET_ACCOUNTS\"/>",
|
||||
"<uses-permission android:name=\"android.permission.MODIFY_AUDIO_SETTINGS\"/>",
|
||||
"<uses-permission android:name=\"android.permission.READ_PHONE_STATE\"/>",
|
||||
"<uses-permission android:name=\"android.permission.CHANGE_WIFI_STATE\"/>",
|
||||
"<uses-permission android:name=\"android.permission.WAKE_LOCK\"/>",
|
||||
"<uses-permission android:name=\"android.permission.CALL_PHONE\"/>",
|
||||
"<uses-permission android:name=\"android.permission.FLASHLIGHT\"/>",
|
||||
"<uses-permission android:name=\"android.permission.ACCESS_COARSE_LOCATION\"/>",
|
||||
"<uses-feature android:name=\"android.hardware.camera\"/>",
|
||||
"<uses-permission android:name=\"android.permission.ACCESS_FINE_LOCATION\"/>",
|
||||
"<uses-permission android:name=\"android.permission.WRITE_SETTINGS\"/>"
|
||||
]
|
||||
},
|
||||
"ios" : {},
|
||||
/* ios打包配置 */
|
||||
"sdkConfigs" : {}
|
||||
}
|
||||
},
|
||||
/* SDK配置 */
|
||||
"quickapp" : {},
|
||||
/* 快应用特有相关 */
|
||||
"mp-weixin" : {
|
||||
/* 微信小程序特有相关 */
|
||||
"appid" : "wx35bc60d481961c1d",
|
||||
"setting" : {
|
||||
"urlCheck" : false
|
||||
},
|
||||
"usingComponents" : true
|
||||
},
|
||||
"mp-alipay" : {
|
||||
"usingComponents" : true
|
||||
},
|
||||
"mp-baidu" : {
|
||||
"usingComponents" : true
|
||||
},
|
||||
"mp-toutiao" : {
|
||||
"usingComponents" : true
|
||||
},
|
||||
"mp-qq" : {
|
||||
"usingComponents" : true
|
||||
},
|
||||
"mp-xhs" : {
|
||||
"usingComponents" : true,
|
||||
"appid" : "63427b653abf67000102aea8"
|
||||
},
|
||||
"locale" : "auto",
|
||||
"fallbackLocale" : "en"
|
||||
}
|
@ -0,0 +1,268 @@
|
||||
{
|
||||
"easycom": {
|
||||
"^u-(.*)": "uview-ui/components/u-$1/u-$1.vue"
|
||||
},
|
||||
"pages": [
|
||||
{
|
||||
"path": "pages/index/index/index",
|
||||
"style": {
|
||||
"enablePullDownRefresh": false,
|
||||
"mp-alipay": {
|
||||
"allowsBounceVertical": "NO"
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"path": "pages/user/login/login",
|
||||
"style": {
|
||||
"navigationBarTitleText": "开心麻花登录"
|
||||
}
|
||||
},
|
||||
{
|
||||
"path": "pages/opera/activity_topics/topics",
|
||||
"style": {}
|
||||
},
|
||||
{
|
||||
"path": "pages/user/user_index/user",
|
||||
"style": {
|
||||
"navigationBarTitleText": "个人中心",
|
||||
"navigationStyle": "custom",
|
||||
"disableScroll": true,
|
||||
"transparentTitle": "auto"
|
||||
}
|
||||
},
|
||||
{
|
||||
"path": "pages/user/order_detail/order_detail",
|
||||
"style": {
|
||||
"navigationBarTitleText": "订单详情"
|
||||
}
|
||||
},
|
||||
{
|
||||
"path": "pages/user/my_order/my_order",
|
||||
"style": {
|
||||
"navigationBarTitleText": "我的订单"
|
||||
}
|
||||
},
|
||||
{
|
||||
"path": "pages/make_order/random_sit/random_sit",
|
||||
"style": {
|
||||
"navigationBarTitleText": "选择票档",
|
||||
"enablePullDownRefresh": false
|
||||
}
|
||||
},
|
||||
{
|
||||
"path": "pages/make_order/make_order/make_order",
|
||||
"style": {
|
||||
"navigationBarTitleText": "确认订单",
|
||||
"enablePullDownRefresh": false
|
||||
}
|
||||
},
|
||||
{
|
||||
"path": "pages/make_order/choose_sit/choose_sit",
|
||||
"style": {
|
||||
"navigationBarTitleText": "选择座位",
|
||||
"enablePullDownRefresh": false,
|
||||
"mp-alipay": {
|
||||
"allowsBounceVertical": "NO"
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"path": "pages/make_order/coupon/coupon",
|
||||
"style": {
|
||||
"navigationBarTitleText": "使用优惠券"
|
||||
}
|
||||
},
|
||||
{
|
||||
"path": "pages/opera/opera/opera_IP",
|
||||
"style": {
|
||||
|
||||
}
|
||||
},
|
||||
{
|
||||
"path": "pages/user/my_show/finished_show/finished_show",
|
||||
"style": {
|
||||
"navigationBarTitleText": "看过的演出"
|
||||
}
|
||||
},
|
||||
{
|
||||
"path": "pages/user/my_show/wanted_show/wanted_show",
|
||||
"style": {
|
||||
"navigationBarTitleText": "想看的演出"
|
||||
}
|
||||
},
|
||||
{
|
||||
"path": "pages/opera/IP_more/IP_more",
|
||||
"style": {
|
||||
"navigationBarTitleText": "大戏"
|
||||
}
|
||||
},
|
||||
{
|
||||
"path": "pages/opera/IP_detail/IP_detail",
|
||||
"style": {}
|
||||
},
|
||||
{
|
||||
"path": "pages/opera/show/show_detail",
|
||||
"style": {
|
||||
"navigationBarTitleText": "开心麻花",
|
||||
"enablePullDownRefresh": false
|
||||
}
|
||||
},
|
||||
{
|
||||
"path": "pages/index/search/search",
|
||||
"style": {
|
||||
"navigationBarTitleText": "搜索",
|
||||
"enablePullDownRefresh": false
|
||||
}
|
||||
},
|
||||
{
|
||||
"path": "pages/user/invoice/invoice_index/invoice_index",
|
||||
"style": {
|
||||
"navigationBarTitleText": "我的发票"
|
||||
}
|
||||
},
|
||||
{
|
||||
"path": "pages/user/invoice/invoice_edit/invoice_edit_newMake",
|
||||
"style": {
|
||||
"navigationBarTitleText": "新建发票抬头"
|
||||
}
|
||||
},
|
||||
{
|
||||
"path": "pages/user/invoice/invoice_edit/invoice_edit_content",
|
||||
"style": {
|
||||
"navigationBarTitleText": "发票抬头信息"
|
||||
}
|
||||
},
|
||||
{
|
||||
"path": "pages/user/invoice/invoice_edit/invoice_edit",
|
||||
"style": {
|
||||
"navigationBarTitleText": "发票抬头信息"
|
||||
}
|
||||
},
|
||||
{
|
||||
"path": "pages/user/invoice/invoice_history/invoice_history",
|
||||
"style": {
|
||||
"navigationBarTitleText": "开票历史"
|
||||
}
|
||||
},
|
||||
{
|
||||
"path": "pages/user/invoice/my_invoice/my_invoice",
|
||||
"style": {
|
||||
"navigationBarTitleText": "我的发票"
|
||||
}
|
||||
},
|
||||
{
|
||||
"path": "pages/user/invoice/make_invoice/make_invoice",
|
||||
"style": {
|
||||
"navigationBarTitleText": "确认开票"
|
||||
}
|
||||
},
|
||||
{
|
||||
"path": "pages/user/discount/discount/discount",
|
||||
"style": {
|
||||
"navigationBarTitleText": "我的优惠券"
|
||||
}
|
||||
},
|
||||
{
|
||||
"path": "pages/user/discount/coupons/coupons",
|
||||
"style": {
|
||||
"navigationBarTitleText": "使用优惠券"
|
||||
}
|
||||
},
|
||||
{
|
||||
"path": "pages/user/discount/discount_ex/discount_ex",
|
||||
"style": {
|
||||
"navigationBarTitleText": "兑换优惠券"
|
||||
}
|
||||
},
|
||||
{
|
||||
"path": "pages/user/discount/discount_avilable/discount_avilable",
|
||||
"style": {
|
||||
"navigationBarTitleText": "可用剧目"
|
||||
}
|
||||
},
|
||||
{
|
||||
"path": "pages/user/auto_service/auto_service",
|
||||
"style": {
|
||||
"navigationBarTitleText": "联系客服"
|
||||
}
|
||||
},
|
||||
{
|
||||
"path": "pages/user/viewer_list/viewer_list",
|
||||
"style": {
|
||||
"navigationBarTitleText": "观演人列表"
|
||||
}
|
||||
},
|
||||
{
|
||||
"path": "pages/index/calendar/calendar",
|
||||
"style": {
|
||||
"navigationBarTitleText": "演出日历",
|
||||
"enablePullDownRefresh": false
|
||||
}
|
||||
},
|
||||
{
|
||||
"path": "pages/index/city/selectcity",
|
||||
"style": {
|
||||
"navigationBarTitleText": "选择城市",
|
||||
"enablePullDownRefresh": false
|
||||
}
|
||||
},
|
||||
{
|
||||
"path": "pages/opera/stage/stage_photo",
|
||||
"style": {
|
||||
"navigationBarTitleText": "分享剧照"
|
||||
}
|
||||
},
|
||||
{
|
||||
"path": "pages/user/discount/answer_topic/answer_topic",
|
||||
"style": {
|
||||
"navigationBarTitleText": "测测我的本命消费人格",
|
||||
"enablePullDownRefresh": false,
|
||||
"disableScroll": true
|
||||
}
|
||||
},
|
||||
{
|
||||
"path": "pages/special/straddlen/new_years",
|
||||
"style": {
|
||||
"navigationBarTitleText": "开心麻花有笑跨年攻略"
|
||||
}
|
||||
}
|
||||
|
||||
],
|
||||
"tabBar": {
|
||||
"color": "#7F8389",
|
||||
"selectedColor": "#FF1D42",
|
||||
"backgroundColor": "#FFFFFF",
|
||||
"borderStyle": "black",
|
||||
"position": "bottom",
|
||||
"list": [{
|
||||
"iconPath": "static/images/ui/index.png",
|
||||
"selectedIconPath": "static/images/ui/indexS.png",
|
||||
"pagePath": "pages/index/index/index",
|
||||
"text": "首页"
|
||||
},
|
||||
{
|
||||
"iconPath": "static/images/ui/IP.png",
|
||||
"selectedIconPath": "static/images/ui/IPS.png",
|
||||
"pagePath": "pages/opera/opera/opera_IP",
|
||||
"text": "剧目精选"
|
||||
},
|
||||
{
|
||||
"iconPath": "static/images/ui/me.png",
|
||||
"selectedIconPath": "static/images/ui/meS.png",
|
||||
"pagePath": "pages/user/user_index/user",
|
||||
"text": "我的"
|
||||
}
|
||||
]
|
||||
},
|
||||
"permission": {
|
||||
"scope.userLocation": {
|
||||
"desc": "你的位置信息将用于小程序获取城市剧场信息"
|
||||
}
|
||||
},
|
||||
"globalStyle": {
|
||||
"navigationBarTextStyle": "black",
|
||||
"navigationBarTitleText": "开心麻花",
|
||||
"navigationBarBackgroundColor": "#ffffff"
|
||||
}
|
||||
}
|
@ -0,0 +1,144 @@
|
||||
const seatImg = {
|
||||
'00': {
|
||||
name: 'default',
|
||||
url: '/static/images/seats/00.png',
|
||||
color:'#D8D8D8'
|
||||
},
|
||||
'01': {
|
||||
name: 'checked',
|
||||
url: '/static/images/seats/01.png',
|
||||
color:'#007800'
|
||||
},
|
||||
A: {
|
||||
name: 'A',
|
||||
url: '/static/images/seats/A.png',
|
||||
color:'#ff3b30'
|
||||
},
|
||||
B: {
|
||||
name: 'B',
|
||||
url: '/static/images/seats/B.png',
|
||||
color:'#fe9400'
|
||||
},
|
||||
C: {
|
||||
name: 'C',
|
||||
url: '/static/images/seats/C.png',
|
||||
color:'#f6eb77'
|
||||
},
|
||||
D: {
|
||||
name: 'D',
|
||||
url: '/static/images/seats/D.png',
|
||||
color:'#4bd863'
|
||||
},
|
||||
E: {
|
||||
name: 'E',
|
||||
url: '/static/images/seats/E.png',
|
||||
color:'#0079fe'
|
||||
},
|
||||
F: {
|
||||
name: 'F',
|
||||
url: '/static/images/seats/F.png',
|
||||
color:'#e6109b'
|
||||
},
|
||||
G: {
|
||||
name: 'G',
|
||||
url: '/static/images/seats/G.png',
|
||||
color:'#ebddd5'
|
||||
},
|
||||
H: {
|
||||
name: 'H',
|
||||
url: '/static/images/seats/H.png',
|
||||
color:'#ff403a'
|
||||
},
|
||||
I: {
|
||||
name: 'I',
|
||||
url: '/static/images/seats/I.png',
|
||||
color:'#f5a433'
|
||||
},
|
||||
J: {
|
||||
name: 'J',
|
||||
url: '/static/images/seats/J.png',
|
||||
color:'#e8ff8c'
|
||||
},
|
||||
K: {
|
||||
name: 'K',
|
||||
url: '/static/images/seats/K.png',
|
||||
color:'#bad4aa'
|
||||
},
|
||||
L: {
|
||||
name: 'L',
|
||||
url: '/static/images/seats/L.png',
|
||||
color:'#abe0ff'
|
||||
},
|
||||
M: {
|
||||
name: 'M',
|
||||
url: '/static/images/seats/M.png',
|
||||
color:'#e5daf9'
|
||||
},
|
||||
N: {
|
||||
name: 'N',
|
||||
url: '/static/images/seats/N.png',
|
||||
color:'#b3907d'
|
||||
},
|
||||
O: {
|
||||
name: 'O',
|
||||
url: '/static/images/seats/O.png',
|
||||
color:'#f45c93'
|
||||
},
|
||||
P: {
|
||||
name: 'P',
|
||||
url: '/static/images/seats/P.png',
|
||||
color:'#db5200'
|
||||
},
|
||||
Q: {
|
||||
name: 'Q',
|
||||
url: '/static/images/seats/Q.png',
|
||||
color:'#e8e363'
|
||||
},
|
||||
R: {
|
||||
name: 'R',
|
||||
url: '/static/images/seats/R.png',
|
||||
color:'#2db3a0'
|
||||
},
|
||||
S: {
|
||||
name: 'S',
|
||||
url: '/static/images/seats/S.png',
|
||||
color:'#bff1ff'
|
||||
},
|
||||
T: {
|
||||
name: 'T',
|
||||
url: '/static/images/seats/T.png',
|
||||
color:'#ffe3fb'
|
||||
},
|
||||
U: {
|
||||
name: 'U',
|
||||
url: '/static/images/seats/U.png',
|
||||
color:'#a60040'
|
||||
},
|
||||
V: {
|
||||
name: 'V',
|
||||
url: '/static/images/seats/V.png',
|
||||
color:'#ffdec9'
|
||||
},
|
||||
W: {
|
||||
name: 'W',
|
||||
url: '/static/images/seats/W.png',
|
||||
color:'#f6ffe3'
|
||||
},
|
||||
X: {
|
||||
name: 'X',
|
||||
url: '/static/images/seats/X.png',
|
||||
color:'#8ab4e8'
|
||||
},
|
||||
Y: {
|
||||
name: 'Y',
|
||||
url: '/static/images/seats/Y.png',
|
||||
color:'#ebf5df'
|
||||
},
|
||||
Z: {
|
||||
name: 'Z',
|
||||
url: '/static/images/seats/Z.png',
|
||||
color:'#a82f5a'
|
||||
}
|
||||
};
|
||||
|
||||
module.exports = seatImg
|
@ -0,0 +1,144 @@
|
||||
const seatImg = {
|
||||
'00': {
|
||||
name: 'default',
|
||||
url: '/static/images/seats/00.png',
|
||||
color:'#D8D8D8'
|
||||
},
|
||||
'01': {
|
||||
name: 'checked',
|
||||
url: '/static/images/seats/01.png',
|
||||
color:'#007800'
|
||||
},
|
||||
A: {
|
||||
name: 'A',
|
||||
url: '/static/images/seats/A.png',
|
||||
color:'#ff3b30'
|
||||
},
|
||||
B: {
|
||||
name: 'B',
|
||||
url: '/static/images/seats/B.png',
|
||||
color:'#fe9400'
|
||||
},
|
||||
C: {
|
||||
name: 'C',
|
||||
url: '/static/images/seats/C.png',
|
||||
color:'#f6eb77'
|
||||
},
|
||||
D: {
|
||||
name: 'D',
|
||||
url: '/static/images/seats/D.png',
|
||||
color:'#4bd863'
|
||||
},
|
||||
E: {
|
||||
name: 'E',
|
||||
url: '/static/images/seats/E.png',
|
||||
color:'#0079fe'
|
||||
},
|
||||
F: {
|
||||
name: 'F',
|
||||
url: '/static/images/seats/F.png',
|
||||
color:'#e6109b'
|
||||
},
|
||||
G: {
|
||||
name: 'G',
|
||||
url: '/static/images/seats/G.png',
|
||||
color:'#ebddd5'
|
||||
},
|
||||
H: {
|
||||
name: 'H',
|
||||
url: '/static/images/seats/H.png',
|
||||
color:'#ff403a'
|
||||
},
|
||||
I: {
|
||||
name: 'I',
|
||||
url: '/static/images/seats/I.png',
|
||||
color:'#f5a433'
|
||||
},
|
||||
J: {
|
||||
name: 'J',
|
||||
url: '/static/images/seats/J.png',
|
||||
color:'#e8ff8c'
|
||||
},
|
||||
K: {
|
||||
name: 'K',
|
||||
url: '/static/images/seats/K.png',
|
||||
color:'#bad4aa'
|
||||
},
|
||||
L: {
|
||||
name: 'L',
|
||||
url: '/static/images/seats/L.png',
|
||||
color:'#abe0ff'
|
||||
},
|
||||
M: {
|
||||
name: 'M',
|
||||
url: '/static/images/seats/M.png',
|
||||
color:'#e5daf9'
|
||||
},
|
||||
N: {
|
||||
name: 'N',
|
||||
url: '/static/images/seats/N.png',
|
||||
color:'#b3907d'
|
||||
},
|
||||
O: {
|
||||
name: 'O',
|
||||
url: '/static/images/seats/O.png',
|
||||
color:'#f45c93'
|
||||
},
|
||||
P: {
|
||||
name: 'P',
|
||||
url: '/static/images/seats/P.png',
|
||||
color:'#db5200'
|
||||
},
|
||||
Q: {
|
||||
name: 'Q',
|
||||
url: '/static/images/seats/Q.png',
|
||||
color:'#e8e363'
|
||||
},
|
||||
R: {
|
||||
name: 'R',
|
||||
url: '/static/images/seats/R.png',
|
||||
color:'#2db3a0'
|
||||
},
|
||||
S: {
|
||||
name: 'S',
|
||||
url: '/static/images/seats/S.png',
|
||||
color:'#bff1ff'
|
||||
},
|
||||
T: {
|
||||
name: 'T',
|
||||
url: '/static/images/seats/T.png',
|
||||
color:'#ffe3fb'
|
||||
},
|
||||
U: {
|
||||
name: 'U',
|
||||
url: '/static/images/seats/U.png',
|
||||
color:'#a60040'
|
||||
},
|
||||
V: {
|
||||
name: 'V',
|
||||
url: '/static/images/seats/V.png',
|
||||
color:'#ffdec9'
|
||||
},
|
||||
W: {
|
||||
name: 'W',
|
||||
url: '/static/images/seats/W.png',
|
||||
color:'#f6ffe3'
|
||||
},
|
||||
X: {
|
||||
name: 'X',
|
||||
url: '/static/images/seats/X.png',
|
||||
color:'#8ab4e8'
|
||||
},
|
||||
Y: {
|
||||
name: 'Y',
|
||||
url: '/static/images/seats/Y.png',
|
||||
color:'#ebf5df'
|
||||
},
|
||||
Z: {
|
||||
name: 'Z',
|
||||
url: '/static/images/seats/Z.png',
|
||||
color:'#a82f5a'
|
||||
}
|
||||
};
|
||||
|
||||
module.exports = seatImg
|
@ -0,0 +1,114 @@
|
||||
<template>
|
||||
<view class="stage_photo">
|
||||
<view class="no" v-if="picture_list.length <= 0">暂无数据</view>
|
||||
<view class="stage_list">
|
||||
<view class="image" v-for="(item, index) in picture_list" :key="index">
|
||||
<image :src="item.url" :data-index="index" @tap="previewMedia"></image>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
// pages/opera/stage/stage_photo.js
|
||||
import { httpUtil, http, login_check } from '../../../utils/util';
|
||||
export default {
|
||||
data() {
|
||||
return {
|
||||
picture_list: [],
|
||||
show_title: '开心麻花',
|
||||
abb_id: ''
|
||||
};
|
||||
}
|
||||
/**
|
||||
* 生命周期函数--监听页面加载
|
||||
*/,
|
||||
onLoad: function (options) {
|
||||
console.log(options);
|
||||
this.setData({
|
||||
show_title: options.show_title,
|
||||
abb_id: options.abb_id
|
||||
});
|
||||
http('/api/v1/share-picture-list', 'get', {
|
||||
abb_id: options.abb_id
|
||||
}).then((res) => {
|
||||
this.setData({
|
||||
picture_list: res.picture_list
|
||||
});
|
||||
});
|
||||
},
|
||||
/**
|
||||
* 生命周期函数--监听页面初次渲染完成
|
||||
*/
|
||||
onReady: function () {},
|
||||
/**
|
||||
* 生命周期函数--监听页面显示
|
||||
*/
|
||||
onShow: function () {},
|
||||
/**
|
||||
* 生命周期函数--监听页面隐藏
|
||||
*/
|
||||
onHide: function () {},
|
||||
/**
|
||||
* 生命周期函数--监听页面卸载
|
||||
*/
|
||||
onUnload: function () {},
|
||||
/**
|
||||
* 页面相关事件处理函数--监听用户下拉动作
|
||||
*/
|
||||
onPullDownRefresh: function () {},
|
||||
/**
|
||||
* 页面上拉触底事件的处理函数
|
||||
*/
|
||||
onReachBottom: function () {},
|
||||
/**
|
||||
* 用户点击右上角分享
|
||||
*/
|
||||
onShareAppMessage: function () {
|
||||
let url = 'https://mahuaimage.oss-cn-qingdao.aliyuncs.com/mini_app/share/home-share.png';
|
||||
return {
|
||||
title: this.show_title,
|
||||
path: '/pages/opera/stage/stage_photo?abb_id=' + this.abb_id + '&show_title=' + this.show_title,
|
||||
imageUrl: this.picture_list.length > 0 ? '' : url
|
||||
};
|
||||
},
|
||||
methods: {
|
||||
previewMedia(e) {
|
||||
let imageList = []
|
||||
this.picture_list.forEach((e) => {
|
||||
imageList.push(e.url);
|
||||
});
|
||||
uni.previewImage({
|
||||
urls: imageList,
|
||||
current: e.currentTarget.dataset.index
|
||||
});
|
||||
}
|
||||
}
|
||||
};
|
||||
</script>
|
||||
<style>
|
||||
/* pages/opera/stage/stage_photo.wxss */
|
||||
.no {
|
||||
text-align: center;
|
||||
line-height: 300rpx;
|
||||
}
|
||||
.stage_photo {
|
||||
padding: 0 20rpx;
|
||||
}
|
||||
.stage_list {
|
||||
display: flex;
|
||||
flex-wrap: wrap;
|
||||
justify-content: space-between;
|
||||
}
|
||||
.stage_list .image {
|
||||
border-radius: 8rpx;
|
||||
width: 330rpx;
|
||||
height: 240rpx;
|
||||
margin: 0rpx 10rpx 10rpx;
|
||||
overflow: hidden;
|
||||
}
|
||||
image {
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
}
|
||||
</style>
|
@ -0,0 +1,670 @@
|
||||
<template>
|
||||
<view class="answer_topic">
|
||||
<view class="topic_index" v-if="step == 0" @tap="get_step" data-step="0">
|
||||
<image src="https://mahuaimage2.oss-cn-qingdao.aliyuncs.com/mini_app/video/61b1d53bcff59c953320c562670249f6bb94574e2764f.jpg"></image>
|
||||
</view>
|
||||
<view class="topic_answer" v-if="step == 1" @tap="" data-step="1">
|
||||
<view class="pop">
|
||||
<image class="title" :src="answer_list.title_url" mode="widthFix"></image>
|
||||
<image class="ans answer1" :src="answer_list.btn1.url" :data-id="answer_list.btn1.id" @tap="next" mode="widthFix"></image>
|
||||
<image class="ans answer2" :src="answer_list.btn2.url" :data-id="answer_list.btn2.id" @tap="next" mode="widthFix"></image>
|
||||
</view>
|
||||
</view>
|
||||
<view class="topic_last" v-if="step == 2">
|
||||
<view class="last_pic">
|
||||
<view class="pic1">
|
||||
<image mode="" :src="answer_piclist[answer_piclist_index].url"></image>
|
||||
</view>
|
||||
<view class="pic2">
|
||||
<image mode="" @tap="ontab" src="https://mahuaimage2.oss-cn-qingdao.aliyuncs.com/mini_app/video/61b30b8c57b8e17be00c1823b5dbda3f316c041ef5226.png"></image>
|
||||
<view class="last_btn" :style="'top:' + btn_top + 'rpx'">
|
||||
<view class="img maRight" @tap="cancel">
|
||||
<image
|
||||
class=""
|
||||
src="https://mahuaimage2.oss-cn-qingdao.aliyuncs.com/mini_app/video/61b1bc3f6cb4b3c6db67097e4dc8d5e75d1a08539b953.png"
|
||||
mode="widthFix"
|
||||
></image>
|
||||
</view>
|
||||
<view class="img maRight">
|
||||
<!-- <button data-id="shareBtn" open-type="share" plain="true" class="share_btn "> -->
|
||||
<image
|
||||
@tap="look"
|
||||
src="https://mahuaimage2.oss-cn-qingdao.aliyuncs.com/mini_app/video/61b1bc3f5538f3c6db67097e4dc8d5e75d1a08539b953.png"
|
||||
mode="widthFix"
|
||||
></image>
|
||||
<!-- </button> -->
|
||||
</view>
|
||||
<view class="img" @tap="oncouon">
|
||||
<image src="https://mahuaimage2.oss-cn-qingdao.aliyuncs.com/mini_app/video/61b1bc3f049cc3c6db67097e4dc8d5e75d1a08539b953.png" mode="widthFix"></image>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
// pages/user/discount/answer_topic/answer_topic.js
|
||||
const app = getApp();
|
||||
export default {
|
||||
data() {
|
||||
return {
|
||||
// iphone_height:app.globalData.screenHeight,
|
||||
step: 0,
|
||||
|
||||
//0首页1答题2结果页
|
||||
pic_list: [
|
||||
{
|
||||
title_url: 'https://mahuaimage2.oss-cn-qingdao.aliyuncs.com/mini_app/video/61b1ada37868a134ab219c9b2cf7fb7bfbf0e4e9da768.png',
|
||||
btn1: {
|
||||
url: 'https://mahuaimage2.oss-cn-qingdao.aliyuncs.com/mini_app/video/61b195f86adf1cc3e07c3d5e38ef85a276c10e5ddc860.png',
|
||||
id: '1'
|
||||
},
|
||||
btn2: {
|
||||
url: 'https://mahuaimage2.oss-cn-qingdao.aliyuncs.com/mini_app/video/61b195f8a0a04cc3e07c3d5e38ef85a276c10e5ddc860.png',
|
||||
id: '2'
|
||||
}
|
||||
},
|
||||
{
|
||||
title_url: 'https://mahuaimage2.oss-cn-qingdao.aliyuncs.com/mini_app/video/61b195f8599a1cc3e07c3d5e38ef85a276c10e5ddc860.png',
|
||||
btn1: {
|
||||
url: 'https://mahuaimage2.oss-cn-qingdao.aliyuncs.com/mini_app/video/61b195f8cc676cc3e07c3d5e38ef85a276c10e5ddc860.png',
|
||||
id: '3'
|
||||
},
|
||||
btn2: {
|
||||
url: 'https://mahuaimage2.oss-cn-qingdao.aliyuncs.com/mini_app/video/61b195f7d01f20410f96c90f22a6a6ee4c1b64851ab55.png',
|
||||
id: '4'
|
||||
}
|
||||
},
|
||||
{
|
||||
title_url: 'https://mahuaimage2.oss-cn-qingdao.aliyuncs.com/mini_app/video/61b195f832aaacc3e07c3d5e38ef85a276c10e5ddc860.png',
|
||||
btn1: {
|
||||
url: 'https://mahuaimage2.oss-cn-qingdao.aliyuncs.com/mini_app/video/61b195f8af5bccc3e07c3d5e38ef85a276c10e5ddc860.png',
|
||||
id: '5'
|
||||
},
|
||||
btn2: {
|
||||
url: 'https://mahuaimage2.oss-cn-qingdao.aliyuncs.com/mini_app/video/61b195f84ab10cc3e07c3d5e38ef85a276c10e5ddc860.png',
|
||||
id: '6'
|
||||
}
|
||||
},
|
||||
{
|
||||
title_url: 'https://mahuaimage2.oss-cn-qingdao.aliyuncs.com/mini_app/video/61b195f87ca49cc3e07c3d5e38ef85a276c10e5ddc860.png',
|
||||
btn1: {
|
||||
url: 'https://mahuaimage2.oss-cn-qingdao.aliyuncs.com/mini_app/video/61b195f8bd3d4cc3e07c3d5e38ef85a276c10e5ddc860.png',
|
||||
id: '7'
|
||||
},
|
||||
btn2: {
|
||||
url: 'https://mahuaimage2.oss-cn-qingdao.aliyuncs.com/mini_app/video/61b195f8daf18cc3e07c3d5e38ef85a276c10e5ddc860.png',
|
||||
id: '8'
|
||||
}
|
||||
}
|
||||
],
|
||||
|
||||
//全部选择题
|
||||
answer_list: [],
|
||||
|
||||
//第几道选择题列表
|
||||
answer_index: 0,
|
||||
|
||||
//第几道选择题下标
|
||||
last_answer: [],
|
||||
|
||||
//选择题结果数组
|
||||
answer_piclist: [
|
||||
{
|
||||
url: 'https://mahuaimage2.oss-cn-qingdao.aliyuncs.com/mini_app/video/61b2b83808e8b8a79bfe7ee712784b5de25c88f71deab.png'
|
||||
},
|
||||
{
|
||||
url: 'https://mahuaimage2.oss-cn-qingdao.aliyuncs.com/mini_app/video/61b2b8388773a8a79bfe7ee712784b5de25c88f71deab.png'
|
||||
},
|
||||
{
|
||||
url: 'https://mahuaimage2.oss-cn-qingdao.aliyuncs.com/mini_app/video/61b2b838cbb4f8a79bfe7ee712784b5de25c88f71deab.png'
|
||||
},
|
||||
{
|
||||
url: 'https://mahuaimage2.oss-cn-qingdao.aliyuncs.com/mini_app/video/61b2b8390cb7f73e3272c120072d298474562fb4c9375.png'
|
||||
},
|
||||
{
|
||||
url: 'https://mahuaimage2.oss-cn-qingdao.aliyuncs.com/mini_app/video/61b307103744f5f39b6f781012e2af323ca4f0eecf111.png'
|
||||
},
|
||||
{
|
||||
url: 'https://mahuaimage2.oss-cn-qingdao.aliyuncs.com/mini_app/video/61b2b8397b7c673e3272c120072d298474562fb4c9375.png'
|
||||
},
|
||||
{
|
||||
url: 'https://mahuaimage2.oss-cn-qingdao.aliyuncs.com/mini_app/video/61b2b839a8ba773e3272c120072d298474562fb4c9375.png'
|
||||
},
|
||||
{
|
||||
url: 'https://mahuaimage2.oss-cn-qingdao.aliyuncs.com/mini_app/video/61b2b839da45873e3272c120072d298474562fb4c9375.png'
|
||||
},
|
||||
{
|
||||
url: 'https://mahuaimage2.oss-cn-qingdao.aliyuncs.com/mini_app/video/61b2b83a1e1ff4d106694ea02244bd19b4a64e16f138d.png'
|
||||
},
|
||||
{
|
||||
url: 'https://mahuaimage2.oss-cn-qingdao.aliyuncs.com/mini_app/video/61b2b83abc2704d106694ea02244bd19b4a64e16f138d.png'
|
||||
},
|
||||
{
|
||||
url: 'https://mahuaimage2.oss-cn-qingdao.aliyuncs.com/mini_app/video/61b2b83aedb904d106694ea02244bd19b4a64e16f138d.png'
|
||||
},
|
||||
{
|
||||
url: 'https://mahuaimage2.oss-cn-qingdao.aliyuncs.com/mini_app/video/61b2b83b45c94ae1a07efdb41747558031b8715bdc618.png'
|
||||
},
|
||||
{
|
||||
url: 'https://mahuaimage2.oss-cn-qingdao.aliyuncs.com/mini_app/video/61b2b83bd4878ae1a07efdb41747558031b8715bdc618.png'
|
||||
},
|
||||
{
|
||||
url: 'https://mahuaimage2.oss-cn-qingdao.aliyuncs.com/mini_app/video/61b2b83c136f1f34ea660275bb582f6c355f0a20f625a.png'
|
||||
},
|
||||
{
|
||||
url: 'https://mahuaimage2.oss-cn-qingdao.aliyuncs.com/mini_app/video/61b3047a97f83788ba5f76578f12c69c7e700b2359e8a.png'
|
||||
},
|
||||
{
|
||||
url: 'https://mahuaimage2.oss-cn-qingdao.aliyuncs.com/mini_app/video/61b2b83c7f7dbf34ea660275bb582f6c355f0a20f625a.png'
|
||||
}
|
||||
],
|
||||
|
||||
//上半截图片
|
||||
answer_piclist_index: 0,
|
||||
|
||||
//当前呈现下标
|
||||
picurl: '',
|
||||
|
||||
previewImage: [
|
||||
'https://mahuaimage2.oss-cn-qingdao.aliyuncs.com/mini_app/video/61b2c6a8bbaad6ce2999e3f480cc263f9ae23dbd36da1.jpg',
|
||||
'https://mahuaimage2.oss-cn-qingdao.aliyuncs.com/mini_app/video/61b2c6a921de19154e0ca4f47047df7f3b84d8eed1d27.jpg',
|
||||
'https://mahuaimage2.oss-cn-qingdao.aliyuncs.com/mini_app/video/61b2c6a97bf399154e0ca4f47047df7f3b84d8eed1d27.jpg',
|
||||
'https://mahuaimage2.oss-cn-qingdao.aliyuncs.com/mini_app/video/61b2c6aa3da9aadfa53d230af143cfa4f485b10219eda.jpg',
|
||||
'https://mahuaimage2.oss-cn-qingdao.aliyuncs.com/mini_app/video/61b3070fe27da69a26c94f09e59eecb5db9a36a56b041.jpg',
|
||||
'https://mahuaimage2.oss-cn-qingdao.aliyuncs.com/mini_app/video/61b2c6abeb72601118e9b6b50f202bf29176e7d951eec.jpg',
|
||||
'https://mahuaimage2.oss-cn-qingdao.aliyuncs.com/mini_app/video/61b2c6ac88549510ff769aeb84272eb112d3eb03b6fd3.jpg',
|
||||
'https://mahuaimage2.oss-cn-qingdao.aliyuncs.com/mini_app/video/61b2c6ad58eeef5811a201efe472044297e3456b90e0a.jpg',
|
||||
'https://mahuaimage2.oss-cn-qingdao.aliyuncs.com/mini_app/video/61b2c6ae54229fc30d50537c9ebdc257f0aae66708ee8.jpg',
|
||||
'https://mahuaimage2.oss-cn-qingdao.aliyuncs.com/mini_app/video/61b2c6afdcec6f41a59769b0ed61302345e344157f6e5.jpg',
|
||||
'https://mahuaimage2.oss-cn-qingdao.aliyuncs.com/mini_app/video/61b2c6b076335b702113774d34aacc39d6290f16b3dae.jpg',
|
||||
'https://mahuaimage2.oss-cn-qingdao.aliyuncs.com/mini_app/video/61b2c6b0db9e9b702113774d34aacc39d6290f16b3dae.jpg',
|
||||
'https://mahuaimage2.oss-cn-qingdao.aliyuncs.com/mini_app/video/61b2c6b1800ea9862ac348bba5b9b263f84f76bcfea7e.jpg',
|
||||
'https://mahuaimage2.oss-cn-qingdao.aliyuncs.com/mini_app/video/61b2c6b243d5343f15ebaa119bfc38a3d770a6e3860fa.jpg',
|
||||
'https://mahuaimage2.oss-cn-qingdao.aliyuncs.com/mini_app/video/61b31e041b3b888b557d0677ee5bf6be3a38e1d9a7dd9.jpg',
|
||||
'https://mahuaimage2.oss-cn-qingdao.aliyuncs.com/mini_app/video/61b2c6b3c7c15796790e23af5f83470f34eb2aee0f0d2.jpg'
|
||||
],
|
||||
|
||||
//完整结果图片
|
||||
//btn按钮top
|
||||
btn_top: 10,
|
||||
|
||||
url: '',
|
||||
id: ''
|
||||
};
|
||||
},
|
||||
onLoad: function (options) {
|
||||
let iphone_height = app.globalData.screenHeight;
|
||||
console.log(iphone_height);
|
||||
|
||||
if (iphone_height <= 600) {
|
||||
this.setData({
|
||||
btn_top: 0
|
||||
});
|
||||
} else {
|
||||
if (iphone_height >= 600 && iphone_height <= 700) {
|
||||
this.setData({
|
||||
btn_top: 4
|
||||
});
|
||||
} else {
|
||||
if (iphone_height >= 700 && iphone_height <= 800) {
|
||||
this.setData({
|
||||
btn_top: 8
|
||||
});
|
||||
} else {
|
||||
if (iphone_height >= 800 && iphone_height <= 850) {
|
||||
this.setData({
|
||||
btn_top: 10
|
||||
});
|
||||
} else {
|
||||
if (iphone_height >= 850) {
|
||||
this.setData({
|
||||
btn_top: 14
|
||||
});
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
this.setData({
|
||||
step: 0,
|
||||
answer_index: 0,
|
||||
answer_list: [],
|
||||
last_answer: []
|
||||
});
|
||||
uni.showShareMenu({
|
||||
withShareTicket: true,
|
||||
menus: ['shareAppMessage', 'shareTimeline']
|
||||
});
|
||||
},
|
||||
/**
|
||||
* 生命周期函数--监听页面初次渲染完成
|
||||
*/
|
||||
onReady: function () {},
|
||||
/**
|
||||
* 生命周期函数--监听页面显示
|
||||
*/
|
||||
onShow: function () {},
|
||||
/**
|
||||
* 生命周期函数--监听页面隐藏
|
||||
*/
|
||||
onHide: function () {},
|
||||
/**
|
||||
* 生命周期函数--监听页面卸载
|
||||
*/
|
||||
onUnload: function () {},
|
||||
/**
|
||||
* 页面相关事件处理函数--监听用户下拉动作
|
||||
*/
|
||||
onPullDownRefresh: function () {},
|
||||
/**
|
||||
* 页面上拉触底事件的处理函数
|
||||
*/
|
||||
onReachBottom: function () {},
|
||||
methods: {
|
||||
/**
|
||||
* 生命周期函数--监听页面加载
|
||||
*/
|
||||
oncouon() {
|
||||
let activity_id = ['3425,3426,3427,3428'];
|
||||
uni.navigateTo({
|
||||
url: '/pages/user/discount/coupons/coupons?activity_id=' + activity_id
|
||||
});
|
||||
},
|
||||
|
||||
cancel() {
|
||||
uni.showToast({
|
||||
title: '重新测试',
|
||||
icon: 'loading',
|
||||
mask: true,
|
||||
duration: 800
|
||||
});
|
||||
setTimeout(() => {
|
||||
this.setData({
|
||||
step: 1,
|
||||
answer_index: 0,
|
||||
answer_list: this.pic_list[0],
|
||||
last_answer: []
|
||||
});
|
||||
}, 800);
|
||||
},
|
||||
|
||||
look(e) {
|
||||
uni.previewImage({
|
||||
urls: [this.previewImage[this.answer_piclist_index]]
|
||||
});
|
||||
},
|
||||
|
||||
next(e) {
|
||||
let id = e.currentTarget.dataset.id;
|
||||
this.last_answer.push(id);
|
||||
|
||||
if (this.answer_index >= 3) {
|
||||
console.log(this.last_answer, 'last_answer');
|
||||
uni.showLoading({
|
||||
title: '正在生成',
|
||||
mask: true
|
||||
});
|
||||
let abswer_arr = this.last_answer;
|
||||
|
||||
if(abswer_arr[0] == '1') {
|
||||
if(abswer_arr[1] == '3') {
|
||||
if(abswer_arr[2] == '5') {
|
||||
if(abswer_arr[3] == '7') {
|
||||
this.setData({
|
||||
answer_piclist_index: 0
|
||||
});
|
||||
} else {
|
||||
this.setData({
|
||||
answer_piclist_index: 1,
|
||||
picurl: this.answer_piclist[this.answer_piclist_index].url
|
||||
});
|
||||
}
|
||||
} else {
|
||||
if(abswer_arr[3] == '7') {
|
||||
this.setData({
|
||||
answer_piclist_index: 2,
|
||||
picurl: this.answer_piclist[this.answer_piclist_index].url
|
||||
});
|
||||
} else {
|
||||
this.setData({
|
||||
answer_piclist_index: 3,
|
||||
picurl: this.answer_piclist[this.answer_piclist_index].url
|
||||
});
|
||||
}
|
||||
}
|
||||
} else {
|
||||
if(abswer_arr[2] == '5') {
|
||||
if(abswer_arr[3] == '7') {
|
||||
this.setData({
|
||||
answer_piclist_index: 4,
|
||||
picurl: this.answer_piclist[this.answer_piclist_index].url
|
||||
});
|
||||
} else {
|
||||
this.setData({
|
||||
answer_piclist_index: 5,
|
||||
picurl: this.answer_piclist[this.answer_piclist_index].url
|
||||
});
|
||||
}
|
||||
} else {
|
||||
if(abswer_arr[3] == '7') {
|
||||
this.setData({
|
||||
answer_piclist_index: 6,
|
||||
picurl: this.answer_piclist[this.answer_piclist_index].url
|
||||
});
|
||||
} else {
|
||||
this.setData({
|
||||
answer_piclist_index: 7,
|
||||
picurl: this.answer_piclist[this.answer_piclist_index].url
|
||||
});
|
||||
}
|
||||
}
|
||||
}
|
||||
} else {
|
||||
if(abswer_arr[1] == '3') {
|
||||
if(abswer_arr[2] == '5') {
|
||||
if(abswer_arr[3] == '7') {
|
||||
this.setData({
|
||||
answer_piclist_index: 8,
|
||||
picurl: this.answer_piclist[this.answer_piclist_index].url
|
||||
});
|
||||
} else {
|
||||
this.setData({
|
||||
answer_piclist_index: 9,
|
||||
picurl: this.answer_piclist[this.answer_piclist_index].url
|
||||
});
|
||||
}
|
||||
} else {
|
||||
if(abswer_arr[3] == '7') {
|
||||
this.setData({
|
||||
answer_piclist_index: 10,
|
||||
picurl: this.answer_piclist[this.answer_piclist_index].url
|
||||
});
|
||||
} else {
|
||||
this.setData({
|
||||
answer_piclist_index: 11,
|
||||
picurl: this.answer_piclist[this.answer_piclist_index].url
|
||||
});
|
||||
}
|
||||
}
|
||||
} else {
|
||||
if(abswer_arr[2] == '5') {
|
||||
if(abswer_arr[3] == '7') {
|
||||
this.setData({
|
||||
answer_piclist_index: 12,
|
||||
picurl: this.answer_piclist[this.answer_piclist_index].url
|
||||
});
|
||||
} else {
|
||||
this.setData({
|
||||
answer_piclist_index: 13,
|
||||
picurl: this.answer_piclist[this.answer_piclist_index].url
|
||||
});
|
||||
}
|
||||
} else {
|
||||
if(abswer_arr[3] == '7') {
|
||||
this.setData({
|
||||
answer_piclist_index: 14,
|
||||
picurl: this.answer_piclist[this.answer_piclist_index].url
|
||||
});
|
||||
} else {
|
||||
this.setData({
|
||||
answer_piclist_index: 15,
|
||||
picurl: this.answer_piclist[this.answer_piclist_index].url
|
||||
});
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
// if (abswer_arr[0] == '1' && abswer_arr[1] == '3' && abswer_arr[2] == '5' && abswer_arr[3] == '7') {
|
||||
// this.setData({
|
||||
// answer_piclist_index: 0
|
||||
// });
|
||||
// } else {
|
||||
// if (abswer_arr[0] == '1' && abswer_arr[1] == '3' && abswer_arr[2] == '5' && abswer_arr[3] == '8') {
|
||||
// this.setData({
|
||||
// answer_piclist_index: 1,
|
||||
// picurl: this.answer_piclist[this.answer_piclist_index].url
|
||||
// });
|
||||
// } else {
|
||||
// if (abswer_arr[0] == '1' && abswer_arr[1] == '3' && abswer_arr[2] == '6' && abswer_arr[3] == '7') {
|
||||
// this.setData({
|
||||
// answer_piclist_index: 2,
|
||||
// picurl: this.answer_piclist[this.answer_piclist_index].url
|
||||
// });
|
||||
// } else {
|
||||
// if (abswer_arr[0] == '1' && abswer_arr[1] == '3' && abswer_arr[2] == '6' && abswer_arr[3] == '8') {
|
||||
// this.setData({
|
||||
// answer_piclist_index: 3,
|
||||
// picurl: this.answer_piclist[this.answer_piclist_index].url
|
||||
// });
|
||||
// } else {
|
||||
// if (abswer_arr[0] == '1' && abswer_arr[1] == '4' && abswer_arr[2] == '5' && abswer_arr[3] == '7') {
|
||||
// this.setData({
|
||||
// answer_piclist_index: 4,
|
||||
// picurl: this.answer_piclist[this.answer_piclist_index].url
|
||||
// });
|
||||
// } else {
|
||||
// if (abswer_arr[0] == '1' && abswer_arr[1] == '4' && abswer_arr[2] == '5' && abswer_arr[3] == '8') {
|
||||
// this.setData({
|
||||
// answer_piclist_index: 5,
|
||||
// picurl: this.answer_piclist[this.answer_piclist_index].url
|
||||
// });
|
||||
// } else {
|
||||
// if (abswer_arr[0] == '1' && abswer_arr[1] == '4' && abswer_arr[2] == '6' && abswer_arr[3] == '7') {
|
||||
// this.setData({
|
||||
// answer_piclist_index: 6,
|
||||
// picurl: this.answer_piclist[this.answer_piclist_index].url
|
||||
// });
|
||||
// } else {
|
||||
// if (abswer_arr[0] == '1' && abswer_arr[1] == '4' && abswer_arr[2] == '6' && abswer_arr[3] == '8') {
|
||||
// this.setData({
|
||||
// answer_piclist_index: 7,
|
||||
// picurl: this.answer_piclist[this.answer_piclist_index].url
|
||||
// });
|
||||
// } else {
|
||||
// if (abswer_arr[0] == '2' && abswer_arr[1] == '3' && abswer_arr[2] == '5' && abswer_arr[3] == '7') {
|
||||
// this.setData({
|
||||
// answer_piclist_index: 8,
|
||||
// picurl: this.answer_piclist[this.answer_piclist_index].url
|
||||
// });
|
||||
// } else {
|
||||
// if (abswer_arr[0] == '2' && abswer_arr[1] == '3' && abswer_arr[2] == '5' && abswer_arr[3] == '8') {
|
||||
// this.setData({
|
||||
// answer_piclist_index: 9,
|
||||
// picurl: this.answer_piclist[this.answer_piclist_index].url
|
||||
// });
|
||||
// } else {
|
||||
// if (abswer_arr[0] == '2' && abswer_arr[1] == '3' && abswer_arr[2] == '6' && abswer_arr[3] == '7') {
|
||||
// this.setData({
|
||||
// answer_piclist_index: 10,
|
||||
// picurl: this.answer_piclist[this.answer_piclist_index].url
|
||||
// });
|
||||
// } else {
|
||||
// if (abswer_arr[0] == '2' && abswer_arr[1] == '3' && abswer_arr[2] == '6' && abswer_arr[3] == '8') {
|
||||
// this.setData({
|
||||
// answer_piclist_index: 11,
|
||||
// picurl: this.answer_piclist[this.answer_piclist_index].url
|
||||
// });
|
||||
// } else {
|
||||
// if (abswer_arr[0] == '2' && abswer_arr[1] == '4' && abswer_arr[2] == '5' && abswer_arr[3] == '7') {
|
||||
// this.setData({
|
||||
// answer_piclist_index: 12,
|
||||
// picurl: this.answer_piclist[this.answer_piclist_index].url
|
||||
// });
|
||||
// } else {
|
||||
// if (abswer_arr[0] == '2' && abswer_arr[1] == '4' && abswer_arr[2] == '5' && abswer_arr[3] == '8') {
|
||||
// this.setData({
|
||||
// answer_piclist_index: 13,
|
||||
// picurl: this.answer_piclist[this.answer_piclist_index].url
|
||||
// });
|
||||
// } else {
|
||||
// if (abswer_arr[0] == '2' && abswer_arr[1] == '4' && abswer_arr[2] == '6' && abswer_arr[3] == '7') {
|
||||
// this.setData({
|
||||
// answer_piclist_index: 14,
|
||||
// picurl: this.answer_piclist[this.answer_piclist_index].url
|
||||
// });
|
||||
// } else {
|
||||
// if (abswer_arr[0] == '2' && abswer_arr[1] == '4' && abswer_arr[2] == '6' && abswer_arr[3] == '8') {
|
||||
// this.setData({
|
||||
// answer_piclist_index: 15,
|
||||
// picurl: this.answer_piclist[this.answer_piclist_index].url
|
||||
// });
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
|
||||
setTimeout(() => {
|
||||
uni.hideLoading();
|
||||
this.setData({
|
||||
step: 2
|
||||
});
|
||||
}, 1000);
|
||||
return;
|
||||
}
|
||||
|
||||
let answer_index = this.answer_index + 1;
|
||||
console.log(answer_index);
|
||||
this.setData({
|
||||
answer_index,
|
||||
answer_list: this.pic_list[answer_index]
|
||||
});
|
||||
},
|
||||
|
||||
get_step(e) {
|
||||
// console.log(e);
|
||||
let step = e.currentTarget.dataset.step;
|
||||
this.setData({
|
||||
answer_list: this.pic_list[0],
|
||||
step: 1
|
||||
});
|
||||
},
|
||||
|
||||
getshare() {
|
||||
this.onShareAppMessage(1);
|
||||
uni.showShareMenu();
|
||||
},
|
||||
|
||||
ontab() {
|
||||
console.log('占位:函数 ontab 未声明');
|
||||
}
|
||||
}
|
||||
};
|
||||
</script>
|
||||
<style>
|
||||
.topic_index {
|
||||
height: 100%;
|
||||
}
|
||||
|
||||
.topic_index image {
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
position: absolute;
|
||||
vertical-align: middle;
|
||||
}
|
||||
.answer1 {
|
||||
margin-top: 100rpx;
|
||||
}
|
||||
.answer2 {
|
||||
margin-top: 40rpx;
|
||||
}
|
||||
|
||||
.topic_answer {
|
||||
width: 100%;
|
||||
height: 100vh;
|
||||
background: url('https://mahuaimage2.oss-cn-qingdao.aliyuncs.com/mini_app/video/61b17100c71a32d5df7e5374efc99918f632401e19f77.jpg');
|
||||
background-size: 100% 100%;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
}
|
||||
|
||||
.pop {
|
||||
width: 75%;
|
||||
display: flex;
|
||||
flex-wrap: wrap;
|
||||
justify-content: center;
|
||||
}
|
||||
.pop image {
|
||||
/* width: 200rpx;
|
||||
height: 200rpx; */
|
||||
/* display: block; */
|
||||
vertical-align: middle;
|
||||
}
|
||||
.pop .ans {
|
||||
}
|
||||
.answer_topic {
|
||||
width: 100%;
|
||||
height: 100vh;
|
||||
}
|
||||
.topic_answer .di {
|
||||
width: 100%;
|
||||
height: 100vh;
|
||||
}
|
||||
.topic_last {
|
||||
/* width: 100%;
|
||||
height: 100vh;
|
||||
background: url("https://mahuaimage2.oss-cn-qingdao.aliyuncs.com/mini_app/video/61b1bd95440f58318553fb8add327f558e5508d778756.jpg");
|
||||
background-size: 100% 100%; */
|
||||
/* position: relative; */
|
||||
}
|
||||
.last_pic {
|
||||
}
|
||||
.last_pic image {
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
vertical-align: middle;
|
||||
}
|
||||
.last_pic .pic1 {
|
||||
height: 74vh;
|
||||
margin-top: -1rpx;
|
||||
}
|
||||
.last_pic .pic2 {
|
||||
margin-top: -1rpx;
|
||||
height: 26vh;
|
||||
position: relative;
|
||||
}
|
||||
.last_btn {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
position: absolute;
|
||||
top: 10rpx;
|
||||
left: 176rpx;
|
||||
}
|
||||
.last_btn .img image {
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
vertical-align: middle;
|
||||
}
|
||||
|
||||
.last_btn .img {
|
||||
width: 128rpx;
|
||||
height: 43rpx;
|
||||
}
|
||||
.maRight {
|
||||
margin-right: 12rpx;
|
||||
}
|
||||
|
||||
.share_btn {
|
||||
border: 0 !important;
|
||||
height: 43rpx;
|
||||
line-height: 43rpx;
|
||||
padding: 0;
|
||||
vertical-align: middle;
|
||||
}
|
||||
</style>
|
@ -0,0 +1,201 @@
|
||||
<template>
|
||||
<view>
|
||||
<view class="line">
|
||||
<view :class="'topLine ' + (swith_area == index ? 'active' : ' ')" :data-index="index" @tap="swith_tab" v-for="(item, index) in switch_space" :key="index">
|
||||
{{ item }}
|
||||
</view>
|
||||
</view>
|
||||
|
||||
<view class="code">
|
||||
<view style="text-align: center"><input type="text" :value="code" placeholder="请输入兑换码" @input="handleInput" class="input" /></view>
|
||||
<button class="_button" :data-index="swith_area" @tap="ex">立即兑换</button>
|
||||
</view>
|
||||
</view>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
// pages/user/discount/discount_ex/discount_ex.js
|
||||
import { http } from '../../../../utils/util';
|
||||
import { host } from '../../../../Gdata';
|
||||
export default {
|
||||
data() {
|
||||
return {
|
||||
switch_space: ['优惠券', '文惠券', '观剧卡'],
|
||||
swith_area: 0,
|
||||
code: ''
|
||||
};
|
||||
}
|
||||
/**
|
||||
* 生命周期函数--监听页面加载
|
||||
*/,
|
||||
onLoad: function (options) {},
|
||||
/**
|
||||
* 生命周期函数--监听页面初次渲染完成
|
||||
*/
|
||||
onReady: function () {},
|
||||
/**
|
||||
* 生命周期函数--监听页面显示
|
||||
*/
|
||||
onShow: function () {},
|
||||
/**
|
||||
* 生命周期函数--监听页面隐藏
|
||||
*/
|
||||
onHide: function () {},
|
||||
/**
|
||||
* 生命周期函数--监听页面卸载
|
||||
*/
|
||||
onUnload: function () {},
|
||||
/**
|
||||
* 页面相关事件处理函数--监听用户下拉动作
|
||||
*/
|
||||
onPullDownRefresh: function () {},
|
||||
/**
|
||||
* 页面上拉触底事件的处理函数
|
||||
*/
|
||||
onReachBottom: function () {},
|
||||
/**
|
||||
* 用户点击右上角分享
|
||||
*/
|
||||
onShareAppMessage: function () {},
|
||||
methods: {
|
||||
swith_tab: function (e) {
|
||||
let swith_area = e.currentTarget.dataset.index;
|
||||
this.setData({
|
||||
swith_area
|
||||
});
|
||||
},
|
||||
|
||||
handleInput(event) {
|
||||
const value = event.detail.value;
|
||||
this.setData({
|
||||
code: value
|
||||
});
|
||||
},
|
||||
|
||||
ex(e) {
|
||||
let token = getApp().globalData.token;
|
||||
let uid = getApp().globalData.uid;
|
||||
let url = ['/api/v1/coupon-exchange', '/api/v1/wenhui-exchange', '/api/v1/card-exchange'];
|
||||
|
||||
if (e.currentTarget.dataset.index == 2) {
|
||||
uni.request({
|
||||
url: host + url[e.currentTarget.dataset.index],
|
||||
data: {
|
||||
card_sn: this.code
|
||||
},
|
||||
method: 'post',
|
||||
header: {
|
||||
token: token,
|
||||
uid: uid
|
||||
},
|
||||
success: (res) => {
|
||||
if (200 == res.data.status) {
|
||||
this.setData({
|
||||
code: null
|
||||
});
|
||||
uni.showToast({
|
||||
title: '兑换成功',
|
||||
icon: 'success',
|
||||
duration: 2000
|
||||
});
|
||||
} else {
|
||||
uni.showToast({
|
||||
title: '兑换码错误',
|
||||
icon: 'fail',
|
||||
duration: 2000
|
||||
});
|
||||
}
|
||||
}
|
||||
});
|
||||
} else {
|
||||
uni.request({
|
||||
url: host + url[e.currentTarget.dataset.index],
|
||||
data: {
|
||||
coupon_sn: this.code
|
||||
},
|
||||
method: 'post',
|
||||
header: {
|
||||
token: token,
|
||||
uid: uid
|
||||
},
|
||||
success: (res) => {
|
||||
if (200 == res.data.status) {
|
||||
this.setData({
|
||||
code: null
|
||||
});
|
||||
uni.showToast({
|
||||
title: '兑换成功',
|
||||
icon: 'success',
|
||||
duration: 2000
|
||||
});
|
||||
} else {
|
||||
uni.showToast({
|
||||
title: '兑换码错误',
|
||||
icon: 'fail',
|
||||
duration: 2000
|
||||
});
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
}
|
||||
}
|
||||
};
|
||||
</script>
|
||||
<style>
|
||||
.line {
|
||||
display: flex;
|
||||
}
|
||||
.line .topLine {
|
||||
width: 33%;
|
||||
text-align: center;
|
||||
padding: 20rpx;
|
||||
color: #7b7b7b;
|
||||
}
|
||||
|
||||
.line .topLine.active {
|
||||
position: relative;
|
||||
color: #181818;
|
||||
font-weight: bold;
|
||||
background: #fff;
|
||||
}
|
||||
|
||||
.line .topLine.active:after {
|
||||
content: ' ';
|
||||
width: 1rem;
|
||||
height: 0.12rem;
|
||||
/* #ifdef MP-ALIPAY */
|
||||
width: 0.4rem;
|
||||
height: 0.04rem;
|
||||
/* #endif */
|
||||
background: #fff;
|
||||
position: absolute;
|
||||
/* bottom: -0.1rem; */
|
||||
bottom: -0.2rem;
|
||||
left: 50%;
|
||||
transform: translateX(-50%);
|
||||
background-color: #ff446b;
|
||||
border-radius: 0.12rem;
|
||||
}
|
||||
|
||||
.code {
|
||||
height: 552rpx;
|
||||
background: #ffffff;
|
||||
padding: 200rpx 0 40rpx 0;
|
||||
}
|
||||
.code .input {
|
||||
width: 60%;
|
||||
margin: 0 20% 100px 20%;
|
||||
border-bottom: 2rpx solid #ff455b;
|
||||
}
|
||||
|
||||
._button {
|
||||
width: 312rpx;
|
||||
background: linear-gradient(90deg, #ff4284 0%, #ff1d42 100%);
|
||||
border-radius: 44rpx;
|
||||
color: #fff;
|
||||
font-size: 28rpx;
|
||||
margin-bottom: 80rpx;
|
||||
margin: auto;
|
||||
}
|
||||
</style>
|
@ -0,0 +1,118 @@
|
||||
<template>
|
||||
<view>
|
||||
<view v-if="'' == invoice_info.is_company" class="no_content">
|
||||
<image class="img" src="/static/images/ui/none.png" />
|
||||
<view class="warn">您目前还没有添加任何发票抬头信息</view>
|
||||
</view>
|
||||
<view class="_container" v-else>
|
||||
<view class="nav" :data-current_item="invoice_info" @tap="_edit">
|
||||
{{ invoice_info.invoice_title }}
|
||||
<image src="/static/images/ui/right1.png" />
|
||||
</view>
|
||||
</view>
|
||||
<button class="_button" @tap="_new">新建发票信息</button>
|
||||
</view>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
// pages/user/invoice/invoice_edit/invoice_edit.js
|
||||
import { http } from '../../../../utils/util';
|
||||
export default {
|
||||
data() {
|
||||
return {
|
||||
show: false,
|
||||
|
||||
invoice_info: {
|
||||
is_company: ''
|
||||
}
|
||||
};
|
||||
}
|
||||
/**
|
||||
* 生命周期函数--监听页面加载
|
||||
*/,
|
||||
onLoad: function (options) {
|
||||
http('/api/v1/invoice-title', 'post').then((res) => {
|
||||
this.setData({
|
||||
invoice_info: res
|
||||
});
|
||||
});
|
||||
},
|
||||
/**
|
||||
* 生命周期函数--监听页面初次渲染完成
|
||||
*/
|
||||
onReady: function () {},
|
||||
/**
|
||||
* 生命周期函数--监听页面显示
|
||||
*/
|
||||
onShow: function () {},
|
||||
/**
|
||||
* 生命周期函数--监听页面隐藏
|
||||
*/
|
||||
onHide: function () {},
|
||||
/**
|
||||
* 生命周期函数--监听页面卸载
|
||||
*/
|
||||
onUnload: function () {},
|
||||
/**
|
||||
* 页面相关事件处理函数--监听用户下拉动作
|
||||
*/
|
||||
onPullDownRefresh: function () {},
|
||||
/**
|
||||
* 页面上拉触底事件的处理函数
|
||||
*/
|
||||
onReachBottom: function () {},
|
||||
/**
|
||||
* 用户点击右上角分享
|
||||
*/
|
||||
onShareAppMessage: function () {},
|
||||
methods: {
|
||||
_edit: function (e) {
|
||||
uni.navigateTo({
|
||||
url: '/pages/user/invoice/invoice_edit/invoice_edit_content?current_item=' + JSON.stringify(e.currentTarget.dataset.current_item)
|
||||
});
|
||||
},
|
||||
|
||||
_new() {
|
||||
uni.navigateTo({
|
||||
url: '/pages/user/invoice/invoice_edit/invoice_edit_newMake'
|
||||
});
|
||||
}
|
||||
}
|
||||
};
|
||||
</script>
|
||||
<style>
|
||||
.no_content_warning {
|
||||
position: fixed;
|
||||
top: 30%;
|
||||
width: 100%;
|
||||
text-align: center;
|
||||
color: #999;
|
||||
}
|
||||
._container {
|
||||
margin: 20rpx 0;
|
||||
}
|
||||
._container .nav {
|
||||
background: #fff;
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
align-items: center;
|
||||
padding: 30rpx;
|
||||
font-size: 28rpx;
|
||||
}
|
||||
._container .nav image {
|
||||
width: 26rpx;
|
||||
height: 26rpx;
|
||||
margin-right: 12rpx;
|
||||
}
|
||||
._button {
|
||||
position: fixed;
|
||||
bottom: 100rpx;
|
||||
width: 312rpx;
|
||||
background: linear-gradient(90deg, #ff4284 0%, #ff1d42 100%);
|
||||
border-radius: 44rpx;
|
||||
color: #fff;
|
||||
font-size: 28rpx;
|
||||
left: 50%;
|
||||
transform: translate(-50%, 0);
|
||||
}
|
||||
</style>
|
@ -0,0 +1,234 @@
|
||||
<template>
|
||||
<view>
|
||||
<view class="inputField">
|
||||
<view class="title">抬头类型</view>
|
||||
<input
|
||||
type="text"
|
||||
disabled
|
||||
:placeholder="is_company == 1 ? '企业单位' : '个人/非企业单位'"
|
||||
:value="is_company == 1 ? '企业单位' : '个人/非企业单位'"
|
||||
@input="titleInput"
|
||||
/>
|
||||
</view>
|
||||
<view class="line">
|
||||
<view class="inputField">
|
||||
<view class="title">抬头名称</view>
|
||||
<input type="text" :placeholder="invoice_title" :value="invoice_title" @input="titleInput" />
|
||||
</view>
|
||||
<view class="inputField" v-if="is_company">
|
||||
<view class="title">纳税人识别号</view>
|
||||
<input type="text" :placeholder="nsrsbh" :value="nsrsbh" @input="nsrsbhInput" />
|
||||
</view>
|
||||
<view class="inputField" style="border: none">
|
||||
<view class="title">发票接收邮箱</view>
|
||||
<input type="text" :placeholder="email" :value="email" @input="emailInput" />
|
||||
</view>
|
||||
</view>
|
||||
|
||||
<view class="_conf">
|
||||
<button class="_button" :disabled="!_edit" @tap="_conf">修改信息</button>
|
||||
<view class="_b" @tap="_delete">删除信息</view>
|
||||
</view>
|
||||
</view>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
// pages/user/invoice/invoice_edit/invoice_eidt_content.js
|
||||
import { http } from '../../../../utils/util';
|
||||
export default {
|
||||
data() {
|
||||
return {
|
||||
edit: false,
|
||||
is_company: '',
|
||||
invoice_title: '',
|
||||
nsrsbh: '',
|
||||
email: ''
|
||||
};
|
||||
},
|
||||
/**
|
||||
* 生命周期函数--监听页面加载
|
||||
*/
|
||||
onLoad: function (options) {
|
||||
if (options.current_item) {
|
||||
let info = JSON.parse(options.current_item);
|
||||
this.setData({
|
||||
is_company: info.is_company,
|
||||
invoice_title: info.invoice_title,
|
||||
nsrsbh: info.nsrsbh,
|
||||
email: info.email
|
||||
});
|
||||
} else {
|
||||
uni.navigateTo({
|
||||
url: '/pages/user/invoice/invoice_edit/invoice_edit'
|
||||
});
|
||||
}
|
||||
},
|
||||
/**
|
||||
* 生命周期函数--监听页面初次渲染完成
|
||||
*/
|
||||
onReady: function () {},
|
||||
/**
|
||||
* 生命周期函数--监听页面显示
|
||||
*/
|
||||
onShow: function () {},
|
||||
/**
|
||||
* 生命周期函数--监听页面隐藏
|
||||
*/
|
||||
onHide: function () {},
|
||||
/**
|
||||
* 生命周期函数--监听页面卸载
|
||||
*/
|
||||
onUnload: function () {},
|
||||
/**
|
||||
* 页面相关事件处理函数--监听用户下拉动作
|
||||
*/
|
||||
onPullDownRefresh: function () {},
|
||||
/**
|
||||
* 页面上拉触底事件的处理函数
|
||||
*/
|
||||
onReachBottom: function () {},
|
||||
/**
|
||||
* 用户点击右上角分享
|
||||
*/
|
||||
onShareAppMessage: function () {},
|
||||
methods: {
|
||||
titleInput(event) {
|
||||
const value = event.detail.value;
|
||||
this.setData({
|
||||
invoice_title: value,
|
||||
_edit: true
|
||||
});
|
||||
},
|
||||
|
||||
nsrsbhInput(event) {
|
||||
const value = event.detail.value;
|
||||
this.setData({
|
||||
nsrsbh: value,
|
||||
_edit: true
|
||||
});
|
||||
},
|
||||
|
||||
emailInput(event) {
|
||||
const value = event.detail.value;
|
||||
this.setData({
|
||||
email: value,
|
||||
_edit: true
|
||||
});
|
||||
},
|
||||
|
||||
_conf: function () {
|
||||
let data1 = {};
|
||||
|
||||
if (this.is_company == 1 && this.nsrsbh && this.invoice_title && this.email) {
|
||||
data1 = {
|
||||
is_company: 1,
|
||||
invoice_title: this.invoice_title,
|
||||
nsrsbh: this.nsrsbh,
|
||||
email: this.email
|
||||
};
|
||||
http('/api/v1/invoice-save-title', 'post', data1).then((res) => {
|
||||
uni.navigateBack();
|
||||
var pages = getCurrentPages(); //获取页面栈
|
||||
|
||||
if (pages.length > 1) {
|
||||
//上一个页面实例对象
|
||||
var prePage = pages[pages.length - 2]; //调用上一个页面的onShow方法
|
||||
|
||||
prePage.onLoad({});
|
||||
}
|
||||
});
|
||||
} else {
|
||||
if (this.is_company == 0 && this.invoice_title && this.email) {
|
||||
data1 = {
|
||||
is_company: 0,
|
||||
invoice_title: this.invoice_title,
|
||||
email: this.email
|
||||
};
|
||||
http('/api/v1/invoice-save-title', 'post', data1).then((res) => {
|
||||
uni.navigateBack();
|
||||
var pages = getCurrentPages(); //获取页面栈
|
||||
|
||||
if (pages.length > 1) {
|
||||
//上一个页面实例对象
|
||||
var prePage = pages[pages.length - 2]; //调用上一个页面的onShow方法
|
||||
|
||||
prePage.onLoad({});
|
||||
}
|
||||
});
|
||||
} else {
|
||||
uni.showToast({
|
||||
title: '请输入完整信息!',
|
||||
icon: 'fail',
|
||||
duration: 2000
|
||||
});
|
||||
}
|
||||
}
|
||||
},
|
||||
|
||||
_delete: function () {
|
||||
uni.showModal({
|
||||
content: '是否删除这条发票信息',
|
||||
|
||||
success(res) {
|
||||
if (res.confirm) {
|
||||
console.log('用户点击确定');
|
||||
http('/api/v1/invoice-title-delete', 'post').then(() => {
|
||||
uni.navigateBack();
|
||||
var pages = getCurrentPages(); //获取页面栈
|
||||
|
||||
if (pages.length > 1) {
|
||||
//上一个页面实例对象
|
||||
var prePage = pages[pages.length - 2]; //调用上一个页面的onShow方法
|
||||
|
||||
prePage.onLoad({});
|
||||
}
|
||||
});
|
||||
} else {
|
||||
if (res.cancel) {
|
||||
console.log('用户点击取消');
|
||||
}
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
}
|
||||
};
|
||||
</script>
|
||||
<style>
|
||||
.inputField {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
width: 100%;
|
||||
font-size: 28rpx;
|
||||
color: #333333;
|
||||
border-bottom: 1rpx solid #eeeeee;
|
||||
padding: 30rpx;
|
||||
}
|
||||
.inputField .title {
|
||||
width: 200rpx;
|
||||
}
|
||||
.inputField input {
|
||||
width: 100%;
|
||||
flex: 1;
|
||||
}
|
||||
|
||||
._conf {
|
||||
position: fixed;
|
||||
bottom: 15%;
|
||||
text-align: center;
|
||||
width: 40%;
|
||||
left: 30%;
|
||||
}
|
||||
._button {
|
||||
width: 312rpx;
|
||||
background: linear-gradient(90deg, #ff4284 0%, #ff1d42 100%);
|
||||
border-radius: 44rpx;
|
||||
color: #fff;
|
||||
font-size: 28rpx;
|
||||
}
|
||||
._b {
|
||||
font-size: small;
|
||||
color: red;
|
||||
padding-top: 20rpx;
|
||||
}
|
||||
</style>
|
@ -0,0 +1,201 @@
|
||||
<template>
|
||||
<view>
|
||||
<view class="_l">
|
||||
<view class="title">抬头类型</view>
|
||||
<view class="content">
|
||||
<view @tap="_A">
|
||||
<icon size="16" :color="is_company ? '#FF1D42' : '#DFDFDF'" type="success" />
|
||||
企业单位
|
||||
</view>
|
||||
<view @tap="_B">
|
||||
<icon size="16" type="success" :color="is_company ? '#DFDFDF' : '#FF1D42'" />
|
||||
个人/非企业单位
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
<view class="line">
|
||||
<view class="inputField">
|
||||
<view class="title">抬头名称</view>
|
||||
<input type="text" placeholder="请输入公司名称" :value="title" @input="titleInput" />
|
||||
</view>
|
||||
<view class="inputField" v-if="is_company">
|
||||
<view class="title">纳税人识别号</view>
|
||||
<input type="text" placeholder="请填写纳税人识别号" :value="nsrsbh" @input="nsrsbhInput" />
|
||||
</view>
|
||||
<view class="inputField" style="border: none">
|
||||
<view class="title">发票接收邮箱</view>
|
||||
<input type="text" placeholder="请填写电子发票接收邮箱" :value="email" @input="emailInput" />
|
||||
</view>
|
||||
</view>
|
||||
|
||||
<button class="_button" @tap="save">保存信息</button>
|
||||
</view>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
// pages/user/invoice/invoice_edit/invoice_edit_newMake.js
|
||||
import { http } from '../../../../utils/util';
|
||||
export default {
|
||||
data() {
|
||||
return {
|
||||
is_company: true,
|
||||
invoice_title: '',
|
||||
nsrsbh: '',
|
||||
email: '',
|
||||
title: ''
|
||||
};
|
||||
}
|
||||
/**
|
||||
* 生命周期函数--监听页面加载
|
||||
*/,
|
||||
onLoad: function (options) {
|
||||
},
|
||||
/**
|
||||
* 生命周期函数--监听页面初次渲染完成
|
||||
*/
|
||||
onReady: function () {},
|
||||
/**
|
||||
* 生命周期函数--监听页面显示
|
||||
*/
|
||||
onShow: function () {},
|
||||
/**
|
||||
* 生命周期函数--监听页面隐藏
|
||||
*/
|
||||
onHide: function () {},
|
||||
/**
|
||||
* 生命周期函数--监听页面卸载
|
||||
*/
|
||||
onUnload: function () {},
|
||||
/**
|
||||
* 页面相关事件处理函数--监听用户下拉动作
|
||||
*/
|
||||
onPullDownRefresh: function () {},
|
||||
/**
|
||||
* 页面上拉触底事件的处理函数
|
||||
*/
|
||||
onReachBottom: function () {},
|
||||
/**
|
||||
* 用户点击右上角分享
|
||||
*/
|
||||
onShareAppMessage: function () {},
|
||||
methods: {
|
||||
|
||||
_A: function () {
|
||||
this.setData({
|
||||
is_company: true
|
||||
});
|
||||
},
|
||||
|
||||
_B: function () {
|
||||
this.setData({
|
||||
is_company: false
|
||||
});
|
||||
},
|
||||
|
||||
titleInput(event) {
|
||||
const value = event.detail.value;
|
||||
this.setData({
|
||||
invoice_title: value
|
||||
});
|
||||
},
|
||||
|
||||
nsrsbhInput(event) {
|
||||
const value = event.detail.value;
|
||||
this.setData({
|
||||
nsrsbh: value
|
||||
});
|
||||
},
|
||||
|
||||
emailInput(event) {
|
||||
const value = event.detail.value;
|
||||
this.setData({
|
||||
email: value
|
||||
});
|
||||
},
|
||||
|
||||
save() {
|
||||
let data = {};
|
||||
console.log(this);
|
||||
|
||||
if (1 == this.is_company) {
|
||||
data = {
|
||||
is_company: 1,
|
||||
invoice_title: this.invoice_title,
|
||||
nsrsbh: this.nsrsbh,
|
||||
email: this.email
|
||||
};
|
||||
} else {
|
||||
if (0 == this.is_company) {
|
||||
data = {
|
||||
is_company: 0,
|
||||
invoice_title: this.invoice_title,
|
||||
email: this.email
|
||||
};
|
||||
}
|
||||
}
|
||||
|
||||
http('/api/v1/invoice-save-title', 'post', data).then((res) => {
|
||||
uni.navigateBack();
|
||||
var pages = getCurrentPages(); //获取页面栈
|
||||
|
||||
if (pages.length > 1) {
|
||||
//上一个页面实例对象
|
||||
var prePage = pages[pages.length - 2]; //调用上一个页面的onShow方法
|
||||
|
||||
prePage.onLoad(prePage.options)
|
||||
}
|
||||
});
|
||||
}
|
||||
}
|
||||
};
|
||||
</script>
|
||||
<style>
|
||||
._l {
|
||||
margin: 20rpx 0;
|
||||
padding: 30rpx;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
font-size: 28rpx;
|
||||
background: #fff;
|
||||
}
|
||||
._l .title {
|
||||
width: 200rpx;
|
||||
}
|
||||
._l .content {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: space-between;
|
||||
width: 100%;
|
||||
flex: 1;
|
||||
}
|
||||
.line {
|
||||
background: #fff;
|
||||
}
|
||||
.inputField {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
width: 100%;
|
||||
font-size: 28rpx;
|
||||
color: #333333;
|
||||
border-bottom: 1rpx solid #eeeeee;
|
||||
padding: 30rpx;
|
||||
}
|
||||
.line .inputField .title {
|
||||
width: 200rpx;
|
||||
}
|
||||
.line .inputField input {
|
||||
width: 100%;
|
||||
flex: 1;
|
||||
}
|
||||
._button {
|
||||
position: fixed;
|
||||
bottom: 100rpx;
|
||||
width: 312rpx;
|
||||
background: linear-gradient(90deg, #ff4284 0%, #ff1d42 100%);
|
||||
border-radius: 44rpx;
|
||||
color: #fff;
|
||||
font-size: 28rpx;
|
||||
left: 50%;
|
||||
transform: translate(-50%, 0);
|
||||
}
|
||||
</style>
|
@ -0,0 +1,79 @@
|
||||
<template>
|
||||
<view>
|
||||
<navigator
|
||||
:url="item.url"
|
||||
class="nav"
|
||||
v-for="(item, index) in [
|
||||
{ title: '开具发票', url: '/pages/user/invoice/my_invoice/my_invoice' },
|
||||
{ title: '开票历史', url: '/pages/user/invoice/invoice_history/invoice_history' },
|
||||
{ title: '发票抬头信息', url: '/pages/user/invoice/invoice_edit/invoice_edit' }
|
||||
]"
|
||||
:key="index"
|
||||
>
|
||||
{{ item.title }}
|
||||
|
||||
<image src="/static/images/ui/right1.png" />
|
||||
</navigator>
|
||||
</view>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
// pages/user/invoice/invoice_index/invoice_index.js
|
||||
import { login_check } from '../../../../utils/util';
|
||||
export default {
|
||||
data() {
|
||||
return {};
|
||||
}
|
||||
/**
|
||||
* 生命周期函数--监听页面加载
|
||||
*/,
|
||||
onLoad: function (options) {
|
||||
login_check(1);
|
||||
},
|
||||
/**
|
||||
* 生命周期函数--监听页面初次渲染完成
|
||||
*/
|
||||
onReady: function () {},
|
||||
/**
|
||||
* 生命周期函数--监听页面显示
|
||||
*/
|
||||
onShow: function () {},
|
||||
/**
|
||||
* 生命周期函数--监听页面隐藏
|
||||
*/
|
||||
onHide: function () {},
|
||||
/**
|
||||
* 生命周期函数--监听页面卸载
|
||||
*/
|
||||
onUnload: function () {},
|
||||
/**
|
||||
* 页面相关事件处理函数--监听用户下拉动作
|
||||
*/
|
||||
onPullDownRefresh: function () {},
|
||||
/**
|
||||
* 页面上拉触底事件的处理函数
|
||||
*/
|
||||
onReachBottom: function () {},
|
||||
/**
|
||||
* 用户点击右上角分享
|
||||
*/
|
||||
onShareAppMessage: function () {},
|
||||
methods: {}
|
||||
};
|
||||
</script>
|
||||
<style>
|
||||
.nav {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
border-bottom: 2rpx solid #dddddd;
|
||||
align-items: center;
|
||||
padding: 30rpx 0;
|
||||
margin: 0 30rpx;
|
||||
font-size: 28rpx;
|
||||
}
|
||||
.nav image {
|
||||
width: 26rpx;
|
||||
height: 26rpx;
|
||||
margin-right: 12rpx;
|
||||
}
|
||||
</style>
|
@ -0,0 +1,159 @@
|
||||
<template>
|
||||
<view>
|
||||
<view v-if="'' == invoice_info.is_company" class="no_content">
|
||||
<image class="img" src="/static/images/ui/none.png" />
|
||||
<view class="warn">您目前还没有添加任何发票抬头信息</view>
|
||||
<button class="_button" @tap="_nav">前往填写开票信息</button>
|
||||
</view>
|
||||
<block wx:else>
|
||||
<view class="_container">
|
||||
<view class="line">
|
||||
<view class="title">发票抬头</view>
|
||||
<view class="content"></view>
|
||||
{{ invoice_info.invoice_title }}
|
||||
</view>
|
||||
<view class="line" v-if="invoice_info.is_company == 1">
|
||||
<view class="title">纳税人识别号</view>
|
||||
<view class="content"></view>
|
||||
{{ invoice_info.nsrsbh }}
|
||||
</view>
|
||||
<view class="line">
|
||||
<view class="title">发票接收邮箱</view>
|
||||
<view class="content"></view>
|
||||
{{ invoice_info.email }}
|
||||
</view>
|
||||
</view>
|
||||
<button class="_button" @tap="_confirm">确认开票</button>
|
||||
</block>
|
||||
</view>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
// pages/user/invoice/make_invoice/make_invoice.js
|
||||
import { http } from '../../../../utils/util';
|
||||
export default {
|
||||
data() {
|
||||
return {
|
||||
invoice_info: {
|
||||
is_company: ''
|
||||
}
|
||||
};
|
||||
}
|
||||
/**
|
||||
* 生命周期函数--监听页面加载
|
||||
*/,
|
||||
onLoad: function (options) {
|
||||
let order_no = options.order_no;
|
||||
http('/api/v1/invoice-title', 'post').then((res) => {
|
||||
res.order_no = order_no;
|
||||
this.setData({
|
||||
invoice_info: res
|
||||
});
|
||||
});
|
||||
},
|
||||
/**
|
||||
* 生命周期函数--监听页面初次渲染完成
|
||||
*/
|
||||
onReady: function () {},
|
||||
/**
|
||||
* 生命周期函数--监听页面显示
|
||||
*/
|
||||
onShow: function () {},
|
||||
/**
|
||||
* 生命周期函数--监听页面隐藏
|
||||
*/
|
||||
onHide: function () {},
|
||||
/**
|
||||
* 生命周期函数--监听页面卸载
|
||||
*/
|
||||
onUnload: function () {},
|
||||
/**
|
||||
* 页面相关事件处理函数--监听用户下拉动作
|
||||
*/
|
||||
onPullDownRefresh: function () {},
|
||||
/**
|
||||
* 页面上拉触底事件的处理函数
|
||||
*/
|
||||
onReachBottom: function () {},
|
||||
/**
|
||||
* 用户点击右上角分享
|
||||
*/
|
||||
onShareAppMessage: function () {},
|
||||
methods: {
|
||||
|
||||
_nav() {
|
||||
wx.navigateTo({
|
||||
url: '/pages/user/invoice/invoice_edit/invoice_edit_newMake'
|
||||
});
|
||||
},
|
||||
|
||||
_confirm: function () {
|
||||
let data1 = this.invoice_info;
|
||||
|
||||
if (data1.is_company == 0) {
|
||||
data1 = {
|
||||
is_company: data1.is_company,
|
||||
invoice_title: data1.invoice_title,
|
||||
email: data1.email,
|
||||
order_no: data1.order_no
|
||||
};
|
||||
}
|
||||
|
||||
uni.showModal({
|
||||
content: '是否确认开票',
|
||||
confirmColor:"#FF333",
|
||||
success(res) {
|
||||
if (res.confirm) {
|
||||
http('/api/v1/invoice-add', 'post', data1).then((res) => {
|
||||
uni.navigateBack();
|
||||
var pages = getCurrentPages(); //获取页面栈
|
||||
|
||||
if (pages.length > 1) {
|
||||
//上一个页面实例对象
|
||||
var prePage = pages[pages.length - 2]; //调用上一个页面的onShow方法
|
||||
|
||||
prePage.onLoad({});
|
||||
}
|
||||
|
||||
uni.showToast({
|
||||
title: '开票成功',
|
||||
icon: 'success',
|
||||
duration: 2000
|
||||
});
|
||||
});
|
||||
} else {
|
||||
if (res.cancel) {
|
||||
// console.log('用户点击取消')
|
||||
}
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
}
|
||||
};
|
||||
</script>
|
||||
<style>
|
||||
._container {
|
||||
background: #fff;
|
||||
}
|
||||
._container .line {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
border-bottom: 2rpx solid #dddddd;
|
||||
align-items: center;
|
||||
padding: 30rpx 0;
|
||||
margin: 0 30rpx;
|
||||
font-size: 28rpx;
|
||||
}
|
||||
._button {
|
||||
position: fixed;
|
||||
bottom: 100rpx;
|
||||
width: 312rpx;
|
||||
background: linear-gradient(90deg, #ff4284 0%, #ff1d42 100%);
|
||||
border-radius: 44rpx;
|
||||
color: #fff;
|
||||
font-size: 28rpx;
|
||||
left: 50%;
|
||||
transform: translate(-50%, 0);
|
||||
}
|
||||
</style>
|
@ -0,0 +1,171 @@
|
||||
<template>
|
||||
<view style="text-align: center;">
|
||||
<!--pages/user/login/login.wxml-->
|
||||
<image class="logo" src="/static/images/ui/KXMH_icon.png" />
|
||||
<!-- #ifndef MP-ALIPAY || MP-BAIDU -->
|
||||
<button class="login" @tap="getUserInfo">授权登录</button>
|
||||
<!-- #endif -->
|
||||
<!-- #ifdef MP-BAIDU -->
|
||||
<button class="login" open-type="getUserInfo" @getuserinfo="getUserInfo">授权登录</button>
|
||||
<!-- #endif -->
|
||||
<!-- #ifdef MP-ALIPAY -->
|
||||
<button class="login" open-type="getAuthorize" @getAuthorize="getUserInfo" onError="onAuthError"
|
||||
scope='userInfo'>
|
||||
授权登录
|
||||
</button>
|
||||
<!-- #endif -->
|
||||
|
||||
<uModalExtra :show="show" showCancelButton @getphonenumber='getPhoneNumber' @onGetAuthorize="onGetAuthorize"
|
||||
confirm-button-open-type="getPhoneNumber" @cancel="show=false">
|
||||
<view class="slot-content dialog_content">
|
||||
<view class="flex jc-c">
|
||||
<u-icon name="checkmark-circle" color="green" size="120rpx" />
|
||||
</view>
|
||||
<view class="_l">用户信息授权成功</view>
|
||||
<view>授权绑定你的手机号</view>
|
||||
</view>
|
||||
</uModalExtra>
|
||||
</view>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
// pages/user/login/login.js
|
||||
import uModalExtra from '@/components/u-modal-extra/u-modal-extra';
|
||||
const app = getApp();
|
||||
import {
|
||||
httpUtil,
|
||||
http,
|
||||
getUserInfoUtil,
|
||||
tokenAndLogin
|
||||
} from '../../../utils/util';
|
||||
export default {
|
||||
components: {
|
||||
uModalExtra
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
code: '',
|
||||
userInfo: null,
|
||||
show: false
|
||||
};
|
||||
},
|
||||
/**
|
||||
* 生命周期函数--监听页面加载
|
||||
*/
|
||||
onLoad: function(options) {
|
||||
|
||||
},
|
||||
/**
|
||||
* 生命周期函数--监听页面初次渲染完成
|
||||
*/
|
||||
onReady: function() {},
|
||||
/**
|
||||
* 生命周期函数--监听页面显示
|
||||
*/
|
||||
onShow: function() {},
|
||||
/**
|
||||
* 生命周期函数--监听页面隐藏
|
||||
*/
|
||||
onHide: function() {},
|
||||
/**
|
||||
* 生命周期函数--监听页面卸载
|
||||
*/
|
||||
onUnload: function() {},
|
||||
/**
|
||||
* 页面相关事件处理函数--监听用户下拉动作
|
||||
*/
|
||||
onPullDownRefresh: function() {},
|
||||
/**
|
||||
* 页面上拉触底事件的处理函数
|
||||
*/
|
||||
onReachBottom: function() {},
|
||||
/**
|
||||
* 用户点击右上角分享
|
||||
*/
|
||||
onShareAppMessage: function() {},
|
||||
methods: {
|
||||
async getUserInfo(e) {
|
||||
let res = await getUserInfoUtil(e)
|
||||
if (res.code) {
|
||||
let code = res.code
|
||||
app.globalData.code = code;
|
||||
this.userInfoX = res.userInfo
|
||||
this.show = true
|
||||
}
|
||||
},
|
||||
async getPhoneNumber(e) {
|
||||
this.setData({
|
||||
show: false
|
||||
})
|
||||
if (!getApp().globalData.code) {
|
||||
uni.showToast({
|
||||
title: '获取手机号被拒'
|
||||
})
|
||||
return
|
||||
}
|
||||
let res = null
|
||||
// #ifndef MP-ALIPAY
|
||||
if (!e.detail.encryptedData || !e.detail.iv) {
|
||||
uni.showToast({
|
||||
title: '请绑定手机号'
|
||||
})
|
||||
return
|
||||
}
|
||||
res = tokenAndLogin(this.userInfoX, getApp().globalData.code, e.detail.encryptedData, e.detail.iv)
|
||||
|
||||
// #endif
|
||||
|
||||
// #ifdef MP-ALIPAY
|
||||
let res1 = await uni.getPhoneNumber()
|
||||
if (!res1) {
|
||||
uni.showToast({
|
||||
title: '手机号获取失败'
|
||||
})
|
||||
return
|
||||
}
|
||||
res = await tokenAndLogin(this.userInfoX, getApp().globalData.code, res1[1].response)
|
||||
// #endif
|
||||
if(!res){
|
||||
uni.showToast({
|
||||
title: '登录接口失效!'
|
||||
});
|
||||
return
|
||||
}
|
||||
setTimeout(() => {
|
||||
uni.showToast({
|
||||
title: '登录成功!'
|
||||
});
|
||||
uni.$emit('initData');
|
||||
uni.navigateBack();
|
||||
var pages = getCurrentPages(); //获取页面栈
|
||||
if (pages.length > 1) {
|
||||
//上一个页面实例对象
|
||||
var prePage = pages[pages.length - 2];
|
||||
prePage.onLoad(prePage.options);
|
||||
}
|
||||
}, 1000);
|
||||
},
|
||||
|
||||
}
|
||||
};
|
||||
</script>
|
||||
<style>
|
||||
/* pages/user/login/login.wxss */
|
||||
.logo {
|
||||
width: 100px;
|
||||
height: 100px;
|
||||
border-radius: 50%;
|
||||
margin: 100px 0 50px 0;
|
||||
}
|
||||
|
||||
.login {
|
||||
width: 500rpx;
|
||||
margin: auto;
|
||||
height: 80rpx;
|
||||
background: linear-gradient(90deg, #ff4284 0%, #ff1d42 100%);
|
||||
border-radius: 44rpx;
|
||||
color: #fff;
|
||||
font-size: 36rpx;
|
||||
line-height: 80rpx;
|
||||
}
|
||||
</style>
|
@ -0,0 +1,162 @@
|
||||
<template>
|
||||
<view>
|
||||
<view v-if="show_list.length == 0" class="no_content">
|
||||
<image class="img" src="/static/images/ui/none.png" />
|
||||
<view class="warn">没有查询到您的观看记录</view>
|
||||
</view>
|
||||
<view v-else class="year_item" v-for="(year_item, index) in show_list" :key="index">
|
||||
<view class="year">
|
||||
{{ index }}
|
||||
</view>
|
||||
|
||||
<view style="padding: 30rpx 30rpx 30rpx 20rpx; background: #fff">
|
||||
<view class="month_item" v-for="(month_item, index1) in year_item" :key="index1">
|
||||
<view class="month">{{ index1 }}</view>
|
||||
|
||||
<view style="width: 100%">
|
||||
<view class="show_list" v-for="(item, index2) in month_item" :key="index2">
|
||||
<view class="split-line" />
|
||||
|
||||
<view class="dot" />
|
||||
|
||||
<view class="info">
|
||||
<view class="time">{{ item.show_date }}</view>
|
||||
<view class="title">{{ item.show_name }}</view>
|
||||
<view class="loc">
|
||||
<view>{{ item.city_name }}</view>
|
||||
<view>{{ item.theater_name }}</view>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
<image class="img" :src="item.pic" />
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
// pages/user/my_show/finished_show/finished_show.js
|
||||
import { http, login_check } from '../../../../utils/util';
|
||||
export default {
|
||||
data() {
|
||||
return {
|
||||
show_list: {
|
||||
},
|
||||
|
||||
year_item: [],
|
||||
month_item: []
|
||||
};
|
||||
}
|
||||
/**
|
||||
* 生命周期函数--监听页面加载
|
||||
*/,
|
||||
onLoad: function (options) {
|
||||
if (login_check(1)) {
|
||||
http('/api/v1/seen-list', 'get').then((res) => {
|
||||
this.setData({
|
||||
show_list: res.show_list
|
||||
});
|
||||
});
|
||||
}
|
||||
},
|
||||
/**
|
||||
* 生命周期函数--监听页面初次渲染完成
|
||||
*/
|
||||
onReady: function () {},
|
||||
/**
|
||||
* 生命周期函数--监听页面显示
|
||||
*/
|
||||
onShow: function () {},
|
||||
/**
|
||||
* 生命周期函数--监听页面隐藏
|
||||
*/
|
||||
onHide: function () {},
|
||||
/**
|
||||
* 生命周期函数--监听页面卸载
|
||||
*/
|
||||
onUnload: function () {},
|
||||
/**
|
||||
* 页面相关事件处理函数--监听用户下拉动作
|
||||
*/
|
||||
onPullDownRefresh: function () {},
|
||||
/**
|
||||
* 页面上拉触底事件的处理函数
|
||||
*/
|
||||
onReachBottom: function () {},
|
||||
/**
|
||||
* 用户点击右上角分享
|
||||
*/
|
||||
onShareAppMessage: function () {},
|
||||
methods: {}
|
||||
};
|
||||
</script>
|
||||
<style>
|
||||
.year {
|
||||
margin: 20rpx 0 10rpx 20rpx;
|
||||
font-size: 36rpx;
|
||||
font-weight: bold;
|
||||
}
|
||||
|
||||
.month_item {
|
||||
display: flex;
|
||||
}
|
||||
|
||||
.month_item .month {
|
||||
width: 80rpx;
|
||||
}
|
||||
|
||||
.show_list {
|
||||
flex: 1;
|
||||
display: flex;
|
||||
position: relative;
|
||||
}
|
||||
|
||||
.show_list .split-line {
|
||||
position: absolute;
|
||||
flex: 0 0 0;
|
||||
margin: 35rpx 0 0 2rpx;
|
||||
border-left: 4rpx dashed #dddddd;
|
||||
left: 7rpx;
|
||||
height: 270rpx;
|
||||
}
|
||||
|
||||
.show_list .dot {
|
||||
width: 22rpx;
|
||||
height: 22rpx;
|
||||
background: #e7e7e7;
|
||||
position: absolute;
|
||||
top: 11rpx;
|
||||
border-radius: 50%;
|
||||
}
|
||||
|
||||
.show_list .info {
|
||||
font-size: 28rpx;
|
||||
flex: 1;
|
||||
margin-left: 40rpx;
|
||||
}
|
||||
|
||||
.show_list .info .time {
|
||||
margin-bottom: 20rpx;
|
||||
font-weight: bold;
|
||||
}
|
||||
|
||||
.show_list .info .title {
|
||||
margin-bottom: 20rpx;
|
||||
}
|
||||
|
||||
.show_list .info .loc {
|
||||
color: #7b7b7b;
|
||||
font-size: 24rpx;
|
||||
}
|
||||
|
||||
.show_list .img {
|
||||
width: 180rpx;
|
||||
height: 270rpx;
|
||||
float: right;
|
||||
margin-bottom: 40rpx;
|
||||
margin-left: auto;
|
||||
}
|
||||
</style>
|
@ -0,0 +1,230 @@
|
||||
<template>
|
||||
<view>
|
||||
<view v-if="follow_list.length == 0" class="no_content">
|
||||
<image class="img" src="/static/images/ui/none.png" />
|
||||
<view class="warn">还未查询到您想看的演出</view>
|
||||
</view>
|
||||
<view v-else class="list" v-for="(item, index) in follow_list" :key="index">
|
||||
<view class="abb_detail" :data-abb_id="item.abb_id" @tap="nav">
|
||||
<image class="img" :src="item.background_pic" mode="aspectFit"/>
|
||||
<view class="title">{{ item.show_name }}</view>
|
||||
<view class="line">
|
||||
<view class="left">
|
||||
<text style="color: #ff1e43" :decode="true">{{ item.show_total }} </text>
|
||||
个剧场在演
|
||||
</view>
|
||||
<view class="right">
|
||||
<text :decode="true">{{ item.follow_total }}人想看 </text>
|
||||
<image :src="'/images/ui/' + (true ? 'liked' : 'like') + '/static/pages/user/my_show/wanted_show/.png'" style="width: 30rpx; height: 28rpx" />
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
<view class="show_detail" v-if="item.show_list[0].cycle_id">
|
||||
<view style="padding: 20rpx 0; background: #fff; margin: 0 20rpx">
|
||||
<view class="item" :data-cycle_id="show_item.cycle_id" @tap="nav1" v-for="(show_item, index1) in item.show_list" :key="index1">
|
||||
<view class="vitr">
|
||||
<view class="month">{{ show_item.month }}</view>
|
||||
<view class="dot" />
|
||||
</view>
|
||||
|
||||
<view class="info">
|
||||
<view class="line" />
|
||||
<view class="city">{{ show_item.city_name }}</view>
|
||||
<view class="time">{{ show_item.show_date }}</view>
|
||||
<view class="area">{{ show_item.theater_name }}</view>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
<view class="more"></view>
|
||||
</view>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
// pages/user/my_show/wanted_show/wanted_show.js
|
||||
import { http, login_check } from '../../../../utils/util';
|
||||
export default {
|
||||
data() {
|
||||
return {
|
||||
follow_list: {
|
||||
length: 0
|
||||
},
|
||||
|
||||
show_item: {
|
||||
cycle_id: '',
|
||||
month: '',
|
||||
city_name: '',
|
||||
show_date: '',
|
||||
theater_name: ''
|
||||
}
|
||||
};
|
||||
}
|
||||
/**
|
||||
* 生命周期函数--监听页面加载
|
||||
*/,
|
||||
onLoad: function (options) {
|
||||
if (login_check(1)) {
|
||||
http('/api/v1/follow-list', 'get').then((res) => {
|
||||
this.setData({
|
||||
follow_list: res.follow_list
|
||||
});
|
||||
});
|
||||
}
|
||||
},
|
||||
/**
|
||||
* 生命周期函数--监听页面初次渲染完成
|
||||
*/
|
||||
onReady: function () {},
|
||||
/**
|
||||
* 生命周期函数--监听页面显示
|
||||
*/
|
||||
onShow: function () {},
|
||||
/**
|
||||
* 生命周期函数--监听页面隐藏
|
||||
*/
|
||||
onHide: function () {},
|
||||
/**
|
||||
* 生命周期函数--监听页面卸载
|
||||
*/
|
||||
onUnload: function () {},
|
||||
/**
|
||||
* 页面相关事件处理函数--监听用户下拉动作
|
||||
*/
|
||||
onPullDownRefresh: function () {},
|
||||
/**
|
||||
* 页面上拉触底事件的处理函数
|
||||
*/
|
||||
onReachBottom: function () {},
|
||||
/**
|
||||
* 用户点击右上角分享
|
||||
*/
|
||||
onShareAppMessage: function () {},
|
||||
methods: {
|
||||
nav(e) {
|
||||
uni.navigateTo({
|
||||
url: '/pages/opera/IP_detail/IP_detail?abb_id=' + e.currentTarget.dataset.abb_id
|
||||
});
|
||||
},
|
||||
|
||||
nav1(e) {
|
||||
uni.navigateTo({
|
||||
url: '/pages/opera/show/show_detail?cycle_id=' + e.currentTarget.dataset.cycle_id
|
||||
});
|
||||
}
|
||||
}
|
||||
};
|
||||
</script>
|
||||
<style>
|
||||
.list {
|
||||
}
|
||||
|
||||
.list .abb_detail {
|
||||
margin: 60rpx 30rpx 0 30rpx;
|
||||
position: relative;
|
||||
box-shadow: 0 12rpx 12rpx 0 rgba(154, 154, 154, 0.2);
|
||||
}
|
||||
.list .abb_detail:after {
|
||||
content: '';
|
||||
position: absolute;
|
||||
width: 32rpx;
|
||||
height: 16rpx;
|
||||
/* background:#9A9A9A;
|
||||
opacity: 0.39; */
|
||||
z-index: -1;
|
||||
border-radius: 32rpx 32rpx 0 0;
|
||||
bottom: 0;
|
||||
left: 359rpx;
|
||||
}
|
||||
.list .abb_detail .img {
|
||||
width: 690rpx;
|
||||
/* height: 460rpx; */
|
||||
}
|
||||
.list .abb_detail .title {
|
||||
text-align: center;
|
||||
padding: 10rpx 0;
|
||||
line-height: 48rpx;
|
||||
font-weight: bold;
|
||||
border-bottom: 2rpx dashed #dddddd;
|
||||
}
|
||||
.list .abb_detail .line {
|
||||
display: flex;
|
||||
padding: 20rpx 0;
|
||||
color: #363636;
|
||||
font-size: 24rpx;
|
||||
background: radial-gradient(circle at 50% 100%, transparent 10px, #fff 0) no-repeat;
|
||||
filter: drop-shadow(6px 6px 6px rgba(154, 154, 154, 0.2));
|
||||
}
|
||||
.list .abb_detail .line .left {
|
||||
width: 50%;
|
||||
margin-left: 60rpx;
|
||||
}
|
||||
.list .abb_detail .line .right {
|
||||
width: 50%;
|
||||
margin-right: 20rpx;
|
||||
display: flex;
|
||||
justify-content: flex-end;
|
||||
align-items: center;
|
||||
}
|
||||
|
||||
.list .show_detail {
|
||||
width: 690rpx;
|
||||
background: #e6e6e6;
|
||||
opacity: 0.59;
|
||||
margin: 0 30rpx;
|
||||
padding-bottom: 20rpx;
|
||||
}
|
||||
.list .show_detail .item {
|
||||
width: 650rpx;
|
||||
background: #fff;
|
||||
display: flex;
|
||||
font-size: 28rpx;
|
||||
}
|
||||
|
||||
.list .show_detail .item .vitr {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
height: min-content;
|
||||
width: 33%;
|
||||
justify-content: flex-end;
|
||||
}
|
||||
.list .show_detail .item .vitr .month {
|
||||
font-weight: bold;
|
||||
color: #181818;
|
||||
}
|
||||
.list .show_detail .item .vitr .dot {
|
||||
width: 20rpx;
|
||||
height: 20rpx;
|
||||
border-radius: 50%;
|
||||
background: #e7e7e7;
|
||||
margin: 0 20rpx;
|
||||
}
|
||||
.list .show_detail .item .info {
|
||||
position: relative;
|
||||
}
|
||||
.list .show_detail .item .info .line {
|
||||
position: absolute;
|
||||
height: 75rpx;
|
||||
border: 1rpx dashed #dddddd;
|
||||
left: -31rpx;
|
||||
bottom: 13rpx;
|
||||
}
|
||||
.list .show_detail .item .info .city {
|
||||
font-weight: bold;
|
||||
}
|
||||
.list .show_detail .item .info .time {
|
||||
font-size: 24rpx;
|
||||
margin: 10rpx 0;
|
||||
}
|
||||
.list .show_detail .item .info .area {
|
||||
font-size: 24rpx;
|
||||
margin-bottom: 10rpx;
|
||||
}
|
||||
|
||||
.more {
|
||||
color: #7b7b7b;
|
||||
text-align: center;
|
||||
margin: 70rpx 0 40rpx 0;
|
||||
}
|
||||
</style>
|
After Width: | Height: | Size: 4.7 KiB |
After Width: | Height: | Size: 5.2 KiB |
After Width: | Height: | Size: 6.8 KiB |
After Width: | Height: | Size: 5.2 KiB |
After Width: | Height: | Size: 5.1 KiB |
After Width: | Height: | Size: 5.1 KiB |
After Width: | Height: | Size: 5.1 KiB |
After Width: | Height: | Size: 5.1 KiB |
After Width: | Height: | Size: 5.1 KiB |
After Width: | Height: | Size: 4.8 KiB |
After Width: | Height: | Size: 5.2 KiB |
After Width: | Height: | Size: 5.1 KiB |
After Width: | Height: | Size: 5.0 KiB |
After Width: | Height: | Size: 4.9 KiB |
After Width: | Height: | Size: 5.0 KiB |
After Width: | Height: | Size: 4.9 KiB |
After Width: | Height: | Size: 5.1 KiB |
After Width: | Height: | Size: 5.1 KiB |
After Width: | Height: | Size: 5.1 KiB |
After Width: | Height: | Size: 5.1 KiB |
After Width: | Height: | Size: 5.1 KiB |
After Width: | Height: | Size: 5.0 KiB |
After Width: | Height: | Size: 4.9 KiB |
After Width: | Height: | Size: 5.2 KiB |